email.addAddress() is not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 02:20 AM
Hi Team,
In the notification, i have added one email script which contain "email.addAddress() function. We need to send mail to CC person also . In activity log, i am able to see that user name is there as a cc but user told me that he is not received any notification.
Please guide me.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 03:53 AM
Hi,
please share the script which you are using to set that
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 03:58 AM
var gr0 = GlideRecord("approvals");
gr0.addQuery('install_status', '1');
gr0.addQuery('monitor', true);
gr0.addQuery('u_segment', current.variables.segment);
gr0.addQuery('attestation_score', '<=', parseInt(current.variables.estimatedShipmentCostUsd, 10));
gr0.addNotNullQuery('location');
gr0.addQuery('u_pbu', current.variables.pbu.getValue());
gr0.addQuery('u_plant_code',current.variables.plantCodeAndPlantName.getValue());
gr0.addQuery('u_cbu', current.variables.cbu.getValue());
gr0.query();
while(gr0.next()){
email.addAddress("cc", gr0.assigned_to.email, gr0.assigned_to.name);
}
In the activity log, i am able to see that user receive notification
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 04:03 AM
Hi,
Did you check for other users in cc are getting notification?
If yes then this user has issue in notification or user preference or inform that user to check in Outlook or mail box settings some issue might be there as well.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 04:05 AM
For CC, can i get log some where?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-24-2020 04:25 AM
Hi,
if you are able to see that user's email in the Copied column in email logs it means it is picking correctly.
please check the points I mentioned above
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader