Add to Email notifications
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-04-2025 12:22 AM
Hi Team,
My requirement is:
add to email notifications:
Is this CIR associated with any migration factory or other enterprise tracking initiatives?
If answer is Yes to the following question(s), display: MF2
Is this in scope of MF2 initiative? = Yes.
How can I achieve these, please help to achieve this requirement.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-04-2025 01:21 AM
Hello @JVINAY
No, this cannot be achieved in ServiceNow. You can do but not directly within the email body (emails are static and cannot dynamically show/hide content after they are sent). However, you can guide users to a dynamic form/survey in ServiceNow to achieve the desired conditional logic.
If my response has helped you hit helpful button and if your concern is solved do mark my response as correct.
Thanks & Regards
Viraj Hudlikar.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-04-2025 01:57 AM
open the required notification or create a new one.
add a dynamic condition In the condition section, check if the field "Is this in scope of MF2 initiative?" is Yes.
use mail script in the email body add a mail script or inline if condition to display "MF2" only when the condition is met:
<% if (current.u_mf2_initiative == 'Yes') { %>
MF2
<% } %>
If using HTML, insert
${current.u_mf2_initiative == 'Yes' ? 'MF2' : ''}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-04-2025 02:34 AM
Hello @JVINAY, if you would like to make email body visible based on the value of another field, you can use email script to achieve this.
refer - Scripting for email notifications
Please mark reply as Helpful/Correct, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-06-2025 05:54 AM - edited 02-06-2025 05:54 AM
Below code i am developing, which table i need to glide ( var grSD = new GlideRecord(' ');)
Please help me to which should I glide/select .
and if it's possible correct my below code.