How to refer BCC from inbound email?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 11:50 PM
Hi,
I want to retrieve BCC address from inbound email. Currently i can refer to, from, cc but not BCC.
could you please help me in this?
Appreciate your quick reply.
Thank You.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 11:55 PM
you can use like below.
email.addAddress("cc", "john.copy@example.com","John Roberts");
email.addAddress("bcc", "john.secret@example.com","John Roberts");
reference : http://wiki.servicenow.com/index.php?title=Scripting_for_Email_Notifications#Adding_CC_and_BCC_recip...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 11:59 PM
Hi Aravind,
I don't want to add address i want to fetch it from incoming email.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-05-2017 11:59 PM
Hi Priyanka,
I think this code will help you this please refer.
if (!current.watch_list.nil()) {
//get watch list addresses and add to cc
var watcherIds = current.watch_list.split(",");
//get user records
var user = new GlideRecord("sys_user");
user.addQuery("sys_id", watcherIds);
user.addQuery("notification", 2); //email
user.addQuery("email", "!=", "");
user.query();
while (user.next()) {
//add to cc list
email.addAddress("cc", user.email, user.getDisplayValue());
email.addAddress("bcc", user.email, user.getDisplayValue());
}
}
Regards,
Ramakrishna
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-06-2017 12:03 AM
Actually my question is I want to check where the email address is there in incoming mail. for that i referred email.recipients but this could not find the BCC address.