How to set TO value dynamically in Email Client Template
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
29m ago
I want to set the To value dynamically in a ServiceNow Email Client Template.
In the Email Client Template JavaScript, I am calling a Script Include function and passing current as a parameter. The Email Client Template is configured for the Incident Communication Task table.
I expected current to represent the GlideRecord of the Incident Communication Task, but it appears to represent the Email Client Template record instead.
Why does current behave this way in an Email Client Template?
What is the correct way to access or pass the Incident Communication Task GlideRecord to the Script Include so that I can use its fields to dynamically populate the To value?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
20m ago
yes this is possible
check below
2 Ways to Leverage Scripting in Email Client Templates
Scripting with Email Client Templates
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader