Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

File System List files in folder, sub-folders - create and update in SharePoint ??

(0) ShareShare
ReportReport
Posted on by 1,597 Super User 2024 Season 1

Hello,


I am building a flow where I need to copy files from a network drive location to a SharePoint Online site.
For now, I am manually triggering the flow however when complete this will be setup on a daily schedule.

Below I have a File System 'List files in folder' action which connection is pointing to the path it is listing files from:

sudosaurus_0-1700150766197.png

As you will see from the below Output, it has listed a folder named "Archive" with a Size of "0" and an xlsx file in the main folder path:

sudosaurus_1-1700151001281.png

However, if I add in a "Get file content using path" action, I am able to see that the "Archive" folder contains other files:

sudosaurus_2-1700151099658.png

How can I structure my flow so that I can copy files from the source path as well as files in any of it's sub-folders?

 

I need to be able to copy all files to a flat structure in a SharePoint site, so there's no need to re-create the folders SPO side but only the files that exist inside the sub-folders on the file system side of things.

 

I've been grappling with for the past couple of days and now coming here for support.

 

Hoping someone can assist me! 🙂

  • sudosaurus Profile Picture
    1,597 Super User 2024 Season 1 on at
    Re: File System List files in folder, sub-folders - create and update in SharePoint ??

    @grantjenkins thanks. I also discovered today that the File System connector has a maximum throughput limit of 30mb per file - so that's put a blocker in our way. I've suggested we use scheduled tasks via ShareGate instead as we already have a subscription with them.

  • grantjenkins Profile Picture
    11,059 Super User 2025 Season 1 on at
    Re: File System List files in folder, sub-folders - create and update in SharePoint ??

    I haven't actually use the File system connectors (our company locks down data gateways fairly strictly).

     

    Looking across the web I couldn't find much with regards to recursively going through folders. However, I did find this post which alludes ot the fact that you can't get nested folders with a single call - very limited indeed. So might need to recursively call the List files in folder to get all the files.

    Solved: How to get a flat listing of all files with path f... - Power Platform Community (microsoft.com)

     

    I'd suggest for the initial load to use something like ShareGate (if you have it available) or PowerShell. Then once you have the files uploaded, set the recurring flow to use When a file is created which won't have any issues with nested folders, etc.

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 566 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 516 Super User 2025 Season 1

#3
stampcoin Profile Picture

stampcoin 492