Add date in scheduled reports.

Community Alums
Not applicable

Hello,

I have a requirement for adding date in subject in scheduled report, how to add some dates?

Example subject: ServiceNow Dump | (<from date> to <to date>)

2 REPLIES 2

Sagar Pagar
Tera Patron

Hi @Community Alums,

 

You can define the email subject in email scripts and call that email scripts in email body.

 

Sample scripts:

 

var subjectLine = "ServiceNow Dump | (" + object.from_date + " to " + object.to_date + ")";
email.setSubject(subjectLine);

 

 

${mail_script:email_script_name}

 

OR

you can write in subject fields itself as:

ServiceNow Dump | ( ${from_date} to ${to_date})

 

 

If my response helps you resolve your issue. Kindly mark it as helpful & correct. It will be helpful to future readers! 👍🏻
Thanks,
Sagar Pagar

The world works with ServiceNow

Community Alums
Not applicable

Hello @Sagar Pagar 

The subject show empty for both from and to.