I am trying to create a flow for our standard operating procedures on SharePoint to automatically send for review and approval when they have not been modified in a year. I have started the automated flow with the "When a file is created or modified" in Sharepoint and wanted to add a condition based on the modified field but I am unsure how to set the condition up. Can anyone help me with this?
Great Thread. Where I am getting stuck is when I get call Get Files "Properties Only" for a sharepoint folder which has 2 excel files, when I see the output it seems blank. So when the condition kicks in, it does not give me error and also does not have any email sent. Does anyone know why value is blank
Here is a link to a post on this site that details how to accomplish your goal. The solution uses a list but it would be the same concept for a library.
Hi Scott -
Created a very similar FLOW to the one outlined here and it's working well - just looking for input to improve it by one step and struggling somewhat when it comes to the Array piece - (maybe method other than an Array will work?)
Flow analyses Doc Library Review Date - compares to current date(TODAY) and if condition (Less Than or Equal ) is met, will fire off an automated email advising that there is a Document due for review.
This is a "one e-mail per document", but one of the Libraries in the scope of this FLOW has 1600 docs in it with about 15 authors- so was hoping to add all docs due for a review by each Document Owner to a single e-mail rather than killing their inbox with dozens of emails.
I tried to create an Array to include the Docs for review by Owner but the output only seems to copy each document into an array with the same number of identical entries ( the number of entries matches the number of individual docs, so I know I'm close, just not sure if i'm positioning the Array properly in the Apply-to-Each module) - Basic flow is below - can you advise where to put the array and how to reference/call it in the email body ( the Output of the Array didn't appear in the Dynamic Content )
Regards,
Paul
Hi @EricKaye ,
It seems you want to check whether the document has been modified in one year.
If the document hasn't been modified in one year, you want to send the document for review.
I have made a test on my side, please take a try with the following workaround:
Here I use the 'Recurrence' trigger, it will run one time every month to check the document.
The expression in the codition is:
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.
Thanks for quick response to my question! You may have to bear with me on this as this is my first time using Flow and I am trying to understand the logic behind it.
I have started creating a reoccuring flow like you suggested with your comment, finished adding the query you suggested but I am lost after that. Should I look into sending an email / approval request to the approver of the document and have that automatically updated the SharePoint document workflow status?
I am also interested in the other ways that this could be done.
Thanks again for all your help!
I believe you should start with a recurrence trigger rather than a Created or Modified trigger. A Flow can only be running for 30 days and then it will be cancelled.
Schedule the Flow to run periodically (Daily? Weekly?) and use a Get Files (properties only) action. In that action, configure a filter query that will filter out any documents that have not been modified in over a year.
I haven't tested this, but the filter query should look something like this:
Modified le 'addDays(utcNow(),365,'yyyy-MM-dd')'
The text inside of the single quotes is an expression and must be entered in the expression window. The single quotes are required.
The problem is that if you loop through the list and start approvals, the Flow will pause on each individual approval until action is taken. You might want to create an entry in a separate list for each item. Then start an approval on the items in the new list. The items in the new list can be linked to the original document..... There are other ways of approaching this as well.
Michael E. Gernaey
66
Super User 2025 Season 1
stampcoin
65
rzaneti
41
Super User 2025 Season 1