Scheduled Report - Email Subject Line with Local Date

jmoore
Mega Expert

I have an existing scheduled report with a date in the email subject line. It is showing UTC date:

javascript:"Changes Approved On " + gs.now()

find_real_file.png

How would I change the code to show the local time? I can show local date/time using the following, but I do not want to include the date.

javascript:"Changes Approved On " + gs.nowDateTime();

 

Thanks!
Jessica

 

1 ACCEPTED SOLUTION

SanjivMeher
Kilo Patron
Kilo Patron

Try gs.nowDateTime().split(' ')[1]


Please mark this response as correct or helpful if it assisted you with your question.

View solution in original post

10 REPLIES 10

jmoore
Mega Expert

Thanks for all the suggestions! This worked for me to show the date:

gs.nowDateTime().split(' ')[0]

 

Ramachandran4
Kilo Contributor

Hello Everyone,

 

My requirement is to display only the yesterday's date in the email subject of the report.

 

Can someone advise ?

 

Thanks

Ramachandran

In the subject line put
javascript:"Yesterday = " + gs.yesterday('').split(' ')[0]

George
Tera Contributor

Same here, can someone help with adding previous days date in the subject line ex.. MM/(current date -1)/YY 

In the subject line put
javascript:"Yesterday = " + gs.yesterday('').split(' ')[0]