Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
It seems quite easy, but I cannot solve one problem: I need to limit the data load period from one date to the previous month. The app has to be reloaded on the 5th calendar day, which also gives me these 4 days of a current month which I don't need.
I'm using this to limit years and it works fine:
set vNumberOfYearsToLoad = 2;
let vBaseDate = num(today());
let vStartDate = AddYears(YearStart($(vBaseDate)),$(vNumberOfYearsToLoad)*-1);
To limit till the last month tried these and haven't succeded:
let vBaseDate = MonthEnd(today(),-1);
let vBaseDate = (Month(Date(Max(Date)))-1);
let vBaseDate = MonthEnd(Max(Date),-1);
Thank you for any ideas!
let vBaseDate = MonthEnd(addmonths(today(), -1))
I tried to re-write variables a bit and it almost works. The only thing is that it deducts the last day of the previous month and have no idea how to avoid it.
This is what I have now:
Let vMinDateFY=YearStart(Today(),-1);
Let vMaxDateFY=Today();
Let vMaxDateFY=MonthEnd(today(),-1);
Let vMaxDateFY=MonthEnd(addmonths(today(), -1));