web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : vAF3i2cejKmNJDqrdEhDhp
Power Automate - Building Flows
Answered

Scan Sharepoint and check for the last time it has been changed

Like (0) ShareShare
ReportReport
Posted on 1 Sep 2021 09:35:47 by 53

Hello everyone,

 

is it possible to scan every file inside a Sharepoint and check for the last time it has been changed? If so please explain how.

 

I want to check that and afterward send out an Email for example and ask the Owner of the file & the person that changed last time if it is still needed. IF the file has been changed 12 months ago for the last time.

 

Thanks

Kerem

I have the same question (0)
  • keremtsc Profile Picture
    53 on 02 Sep 2021 at 11:38:35
    Re: Scan Sharepoint and check for the last time it has been changed

    Thanks again! (What a silly mistake by me)

    I have created this with your help:flow.PNG

     


    What would I have to put into the condition 1 to get this to work?

  • Mitanshu Profile Picture
    1,635 Moderator on 01 Sep 2021 at 11:59:42
    Re: Scan Sharepoint and check for the last time it has been changed

    @keremtsc wrote:

    @happyume 

    Thank you again! I see what I did wrong there.

    This time though it should be right but it still gives me the error: The expression "Modified It '2020-09-01T11:48:51.4363547Z'" is not valid. Creating query failed.


     

    aaa.PNG

     


    The keyword after Modified is lt and NOT It 

     

    Here, lt stands for less than, you have used i instead.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If this post or my previous reply was useful in other ways, please consider giving it Thumbs Up.

  • keremtsc Profile Picture
    53 on 01 Sep 2021 at 11:52:02
    Re: Scan Sharepoint and check for the last time it has been changed

    @happyume 

    Thank you again! I see what I did wrong there.

    This time though it should be right but it still gives me the error: The expression "Modified It '2020-09-01T11:48:51.4363547Z'" is not valid. Creating query failed.


     

    aaa.PNG

     

  • Mitanshu Profile Picture
    1,635 Moderator on 01 Sep 2021 at 11:44:31
    Re: Scan Sharepoint and check for the last time it has been changed

    From my original solution, please see screenshot below on how it should look:

     

    happyume_0-1630496597562.png


    To add the expression for addDays(), use the Dynamic content window:

    happyume_1-1630496641307.png

     

    Are you able to share your screenshot on how you are writing this syntax, so that we can troubleshoot it?

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If this post or my previous reply was useful in other ways, please consider giving it Thumbs Up.

  • keremtsc Profile Picture
    53 on 01 Sep 2021 at 11:37:22
    Re: Scan Sharepoint and check for the last time it has been changed

    @happyume 

     

    The expression "Modified It @{addDays(utcNow(),-365)}" is not valid. Creating query failed.

     

    Sorry if I do some simple things wrong. I put it in single quotes.

  • Mitanshu Profile Picture
    1,635 Moderator on 01 Sep 2021 at 11:32:31
    Re: Scan Sharepoint and check for the last time it has been changed

    @keremtsc wrote:

    Hi @happyume,

     

    I am getting this errorcode:

    The expression "ModifiedIt 2020-09-01T11:28:06.0630813Z" is not valid. Creating query failed.


    There should be a space between Modified and lt

    Also, the date needs to be within single quotes

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If this post or my previous reply was useful in other ways, please consider giving it Thumbs Up.

  • keremtsc Profile Picture
    53 on 01 Sep 2021 at 11:30:24
    Re: Scan Sharepoint and check for the last time it has been changed

    Hi @happyume,

     

    I am getting this errorcode:

    The expression "ModifiedIt 2020-09-01T11:28:06.0630813Z" is not valid. Creating query failed.

  • Verified answer
    Mitanshu Profile Picture
    1,635 Moderator on 01 Sep 2021 at 09:58:21
    Re: Scan Sharepoint and check for the last time it has been changed

    You can create a recurring/schedule Flow and then Get Files from your SharePoint Document Library

    To make sure you only get files which were Modified 365 days ago, use Filter query as seen in screenshot below:

     

    Modified lt '@{addDays(utcNow(),-365)}'

     

     

    happyume_0-1630490238186.png

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If this post or my previous reply was useful in other ways, please consider giving it Thumbs Up.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading complete