cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Updating file properties + loop

What flow can i build that will update file properties to add 365 days to a certain Date and Time column? I could use "when an item is created or modified" but i only want to add the 365 days when the file has been modified by manager, not to any file that is created.

I did try with the "when an item is created or modified" -> "update file properties" but it also bugs as it creates a loop.

Or, even better, can I somehow create a button in the web part that triggers the updating flow?

Thank you

 

3 REPLIES 3
Highlighted
Solution Sage
Solution Sage

Re: Updating file properties + loop

Hi @AlexandruCazan ,

I suggest you use the 'For a selected file' trigger of you flow.

Capture1.PNG

Best Regards,

Community Support Team _ Zhongys

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Highlighted
Frequent Visitor

Re: Updating file properties + loop

Thats a good suggestion. It fits my needs, but can you help me with the addDays function?

I want to add 365 days everytime i run the flow, but it gets stucked at 2020, it doesn't matter if i have the review date to 2019 or 2009, if i run the flow, it modifies the date to 2020, so i think the 'utcNow' timestamp is the problem.

c1.PNG

Highlighted
Solution Sage
Solution Sage

Re: Updating file properties + loop

Hi @AlexandruCazan ,

The 'utcNow' function is to return the date of now time.

The year is 2019 now, so after add 365 days, it will always return 2020.

For more information about 'Date and time functions', please take a reference:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#d...

Best Regards,

Community Support Team _ Zhongys

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
secondImage

August 2020 CYST Winners!

Check out the winners of the recent 'Can You Solve These?' community challenge!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Top Kudoed Authors
Users online (3,925)