The CreatorCon Call for Content is officially open! Get started here.

Email preview in notification is showing blank

bbf35621
Kilo Sage

Hi guys,

I must have simply missed something or did it wrong. I created an email template for the brand's standard layout. The template looked good, but when I attached it to the notification I created and tested it, it showed blank in the preview. Does anyone know why?

NotificationNotificationEmail TemplateEmail Template

1 ACCEPTED SOLUTION

I was able to fix the blank content issue by using an email script instead. I still don't know why it isn't working to use variables in notification but it's working by using email script.

View solution in original post

4 REPLIES 4

James Chun
Kilo Patron

Hi @bbf35621,

 

First of all, did you select the right record when you were doing a preview?

 

Also, I don't believe you can access the ${notification:body} object from an Email template.

You would need to use an Email layout instead - https://docs.servicenow.com/bundle/washingtondc-platform-administration/page/administer/notification...

 

Cheers

Yes. All in the right table. I created those in the scoped app. I have checked the email logs and it goes triggered and the subject is correct, but the body is blank. I moved the HTML layout from the template to the email layout, result still the same. I have tried to test it just the notification itself, the blank is still showing. Here is a system log preview, result.jpg

Right, I would recommend simplifying the notification and testing one step at a time.

For example:

  • Start off by removing all the variables, email scripts (if any), and templates from the notification (body and subject). i.e. leave only fixed text in the subject and the body. Preview it, and if it works, move on to the next step.
  • Add one variable at a time and perform a preview. If it works, move on to the next step.
  • Add the email template and perform a preview.

Is the notification built on the same scope as the table? If not, it may be a scope/access issue.

 

I was able to fix the blank content issue by using an email script instead. I still don't know why it isn't working to use variables in notification but it's working by using email script.