Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Unanswered

Create Flow for Moving Attachments Based on Folder Structure in SharePoint

(1) ShareShare
ReportReport
Posted on by 2

Hello everyone!

I'm trying to create a flow in Power Automate that integrates with a PowerApps form and moves attachments to specific folders in a SharePoint document library based on information extracted from a SharePoint list. Below, I outline what I'm trying to achieve:

Flow Objective:

  • When a new form is submitted in PowerApps, I want the flow to:
    1. Retrieve the attachment from the item in the SharePoint list.
    2. Check the information for Function, Industry, and Client stored in that list.
    3. Check in the document library if there is a folder with the name of the Function:
      • If yes, go into that folder and check if there is a subfolder with the name of the Industry:
        • If yes, go into that subfolder and check if there is a subfolder with the name of the Client:
          • If yes, move the attachment to that folder.
          • If no, create the Client folder and move the attachment there.
        • If no, create the Industry folder and the Client subfolder, then move the attachment to the newly created Client folder.
      • If no, create the Function folder, the Industry subfolder, and the Client subfolder, moving the attachment to the newly created Client folder.
Data Sources:
  • SharePoint List: Contains information about Function, Industry, and Client.
  • SharePoint Library: Where the folders should be created and where the attachment will be moved.
  • SudeepGhatakNZ Profile Picture
    14,381 Most Valuable Professional on at
    Create Flow for Moving Attachments Based on Folder Structure in SharePoint
    Is you flow not working? Are you struggling with an error?

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June 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 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1

Featured topics

Restore a deleted flow