Hi!
Here's a snapshot of the table I'm working on. I am filtering rows whose start and end dates are current, based on utcNow(), and this flow will run as a weekly report.
In addition, I have a sharepoint list that contains Fiscal calendar details, like WeekOfYear, DayofYear, etc.
Should I use that to determine what week the 'Title' is in based on the 'Proposed Start Date'? For example, I want to use flow to output based on today's date, that we are on week '3' of the 'Siig Inc' row because its 'Proposed Start Date' is '07 Jun 2021'. I guess that mean using utcNow() to count number of weeks from 'Proposed Start Date'.
The values will be collected into an email body, arranged first by the Select action adn will look like:
'TITLE' 'Proposed Start Date' 'Proposed End Date' 'Event Week Number'
I was hoping for an easier way without having to reference the Fiscal calendar SP list, like a formula I can plug into an 'Apply to each' loop.
Thanks!
@ccc333ab - I just tried it now, and it works flawlessly!
Many thanks!
No, you shouldn't have to just as long as the date is in a date format (not a string).
Thanks @ccc333ab
Ok, I'll try this out today. If I already have the excel string 'Proposed Start Date' formatted to MM-dd-yyyy from a previous flow, should I still convert it to yyyy-MM-dd first?
Can you just use a mathematical formula to calcualte it out? Assuming start date is always Monday...you can:
So in Power Automate, I'd use this formula:
add(div(div(sub(ticks(utcnow()),ticks(formatDateTime(variables('strDate'),'yyyy-MM-dd'))),864000000000),7),1)
Just replace variables('strDate') with whatever your start date is. Explaning this a bit but I can explain it moreif you want:
Michael E. Gernaey
497
Super User 2025 Season 1
David_MA
436
Super User 2025 Season 1
Riyaz_riz11
244
Super User 2025 Season 1