Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

The 4th edition of the Campaign Community Lens newsletter is out now!

Reports: How could I get the current date as default for an variable?

Avatar

Level 2

Hi,

I would present by default a date range like: start date = today and end date today+2weeks. I tried to set some vaiable and insert some js code into the default field, but it doesn't work! Please find more in the attachement.

report with start and end date.JPG

Variable for report.JPG

Many thanks

robert

0 Replies

Avatar

Employee Advisor

Hi Robert,

One quick way will be to do a preview of your web application and find the id attribute details for both textboxes.

Use JavaScript to calculate current date and the End Date and assign it either using JS or jQuery, whichever is feasible for you.

Regards,

Vipul