Hi,
I'm currently trying to write the date that is 91 days from my end date (which is set in a variable).
My variable varPayPeriodSelectedDropdownEndDate = 3/31/2022
I have written this code to start but not sure how to get the return date...
DateValue(DateDiff(Today(), varPayPeriodSelectedDropdownEndDate)-91)
This gives me a value of 1/1/1990?
I would like to SET the datediff value in a variable as well to be used later.
Appreciate your support 🙂
Solved! Go to Solution.
The formula is correct. But for something else...my bad for not noticing.
The formula should be:
DateAdd(varPayPeriodSelectedDropdownEndDate, -91)
Please consider changing your Formula to the following:
DateAdd(Today(), varPayPeriodSelectedDropdownEndDate, -91)
I hope this is helpful for you.
https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-dateadd-datediff
DateDiff(Today(), DateAdd(varPayPeriodSelectedDropdownEndDate,-91,Days), Days)
That should get you the diference. It will return an int (1, 2, 3, 4, etc)
To set that in a var:
Set(varDiference, DateDiff(Today(), DateAdd(varPayPeriodSelectedDropdownEndDate,-91,Days), Days))
If you need additional help please tag me in your reply and please like my reply.
If my reply provided you with a solution, pleased mark it as a solution ✔️!
Best regards,
Gonçalo Nogueira
Check my LinkedIn!
Buy me a coffee!
Check my User Group (pt-PT)!
Last Post on Community
My website!
Thank you for your quick response, the label field returns a blank entry:
The formula is correct. But for something else...my bad for not noticing.
The formula should be:
DateAdd(varPayPeriodSelectedDropdownEndDate, -91)
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
Power Platform release plan for the 2022 release wave 2 describes all new features releasing from October 2022 through March 2023.
User | Count |
---|---|
199 | |
97 | |
56 | |
51 | |
41 |
User | Count |
---|---|
265 | |
157 | |
83 | |
80 | |
56 |