Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello ,
Am testing my QV app and hence need to force the function today() which I have used to calculate MTD and YTD numbers to a date in the past.
Is the only way to achieve this is set the OS date or is there any other trick ?
TIA
Lav
I don't know any other way then setting the OS date and time to another value to directly affect the today() call.
But you can replace all your today() function calls with a variable vToday, then set the variable in default mode to today() and to any other date using makedate() when testing.
Hi Ram,
Use Variable in script mode;
Let vToDay= Date(Today()-1,'DD/MM/YYYY')
Without script : Create a variable vToDay
= Date(Today()-1,'DD/MM/YYYY')