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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Automatic transfer of ...
Power Automate
Unanswered

Automatic transfer of files based on a condition

(0) ShareShare
ReportReport
Posted on by 54

I'm trying to make a flow that will automatically move any files from a test folder into a destination folder and put it in the correct subfolder based on the name. For example, if I upload a file named, "test 1", I want it to look at the name of the uploaded file when it gets uploaded and check if that name exists in the destination folder. If it does, then move that file to the corresponding subfolder(which would be a subfolder called, "test 1" in this case). If it doesn't exist in the folder, make a new subfolder with that name in the destination folder.

 

The condition I have where name is equal to name takes the file name from the test folder and checks if it's equal to the destination file name. I'm not sure if that will work because I need it to check for any folder name that's equal to the test folder files, but it will give you an idea of what I'm trying to do. Any suggestions or revisions would be appreciated.

 

This is what I'm working with right now. 

Screenshot of flow.png

 

Categories:
  • Rhiassuring Profile Picture
    8,692 Moderator on at

    My main question is ... are you creating a subfolder for every file you receive? You won't receive Test 1.docx twice? (Because then, if it's the exact same name, it'd overwrite.) 

  • stolliver Profile Picture
    54 on at

    You bring up a good point. Perhaps I should change it look for files that start with ‘test 1’ and then anything after that can further classify the file without causing it to be overwritten. Can I simply change the condition to ‘starts with’ or would I need more changes?

  • Rhiassuring Profile Picture
    8,692 Moderator on at

    Well ... it depends. How much of the "Starts With" will you be able to depend on? Like, if your files are "Project 12345 - Status Report 1", then you'd want to say ... starts with the first 13 characters, so you'd catch anything else with Project 12345. 

     

    Is there any consistency in these filenames?

  • stolliver Profile Picture
    54 on at

    The file names are not set in stone yet. I could do something like what you’re talking about with the project 12345, but we’re planning on just using first name and last name. If someone has the same first and last as another person then we use the middle name. Would that work?

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 414

#2
11manish Profile Picture

11manish 335 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 274

Last 30 days Overall leaderboard