How to assign a user to assign_to field through email
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 03:26 AM
Hi All, i need to assignee a user to Assigned_to field Through email. Can anyone Please help me in this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 04:11 AM
Hi Abhishek Thank you so much for clear explanation But i have a issue that will work only with body contains(:) right.?? Here we are using email tags not (:) email tag will be like this ~@ABC xyz@gmail.com after that tag what is the email id is appearing that name should be assigned filed. Can you please help me in that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 05:56 AM
Hi Manisha ,
You can use this script in your inbound action.
email.origemail : Contains the email sender's address as listed in the email Headers.
From email addres it will take xyz as a username and that username must be there in servicenow then only it will assigned to that xyz person.
var setAssign = email.origemail;
var getAssign = setAssign.substring(0, setAssign.lastIndexOf("@"));
gs.log("^^^^^^"+ getAssign);
current.assigned_to = getAssign;
Please give it a try and let me know.I have tested in my environment it is working fine.
Thanks,
Abhishek