I found this very helpful function for calculating last day of current month in some forum som time ago:
Set(varLastDayOfMonth, "" & Month(Today()) & "" & "/" & "" & Day(DateAdd(DateAdd(Today(),1,TimeUnit.Months),-Day(Today()),TimeUnit.Days)) & "" & "/" & "" & Year(Today()) & "");
This has been working great when my PowerApp is executed in Chrome.
However, now I have to share it in Teams, and then the function calculates wrong date...
Instead of show 03/31/2023 it says 07/03/20225... Same thing in Edge. Why??
Regards,
John Martin

Report
All responses (
Answers (