AnsweredAssumed Answered

Date Format and Calculating Last Day of Month

Question asked by g.bathurst on Feb 2, 2019
Latest reply on Feb 7, 2019 by g.bathurst

Hello All,

 

This should be so simple... I collect a start date via Custom DIalog Box (ie: 01-01-2018)

I set a start variable $$Start_date,

 

I the calculate the LAST day of the month and set a variable $$End_date with the calculation,

GetAsDate ( Date (Month ($$Start_date) + 1, 0, Year ($$Start_date)))

 

Then set the global date fields to run a report.

 

Set Field [ Report_Generator::g_FIND Start Date ; $$Start_date ]

Set Field [ Report_Generator::g_FIND End Date ; $$End_date ]

 

Perform Script [ Specified: From list ; “Create Report” ; Parameter

 

Problem:

The last date calculation returns a strange format, $$Start_date - 01-01-2018 generates an $$End_date 31/1/2018, presumably DD/MM/YYYY format. The global date field returns a ? when the $$End_date variable is entered into the field. All attempts at transposing the day/month fails.

 

I'm on a Mac and as a Canadian have my system date form set to MM-DD-YYYY

 

HELP, please

Outcomes