Page 1 of 1

Moving files based on sub-folder name (multiple sub-folders)

PostPosted: Sat Jan 07, 2023 10:20 pm
by BobbyPlaysGames
SOLVED!

Hey all. Appreciate some help with following challenge. Structure of folders/files is:

Source:
Folder A
Folder X
File 1
File 2
Folder Y
File 1
File 2
File 3
...

Target:
Folder B
Folder C

I want to move the files in Folder X to Folder B, and those in Folder Y to Folder C. I have individual rules for Folders X & Y already, and these work just fine. However, I would like to have a single set of rules for Folder A that deals with all sub-folders contained.

Appreciate any guidance on this.

Re: Moving files based on sub-folder name (multiple sub-fold

PostPosted: Mon Jan 09, 2023 10:31 am
by Mr_Noodle
What is the relationship between X and B as well as Y and C?

Re: Moving files based on sub-folder name (multiple sub-fold

PostPosted: Mon Jan 09, 2023 7:23 pm
by BobbyPlaysGames
Mr_Noodle wrote:What is the relationship between X and B as well as Y and C?


I've since resolved. Key was not to look at Processing Subfolders in the help menu, but instead to look at Using Nested Conditions:

Rule 1: Go into subfolders
Rule 2: Move to Folder B
Code: Select all
If all of the following conditions are met
     If all of the following conditions are met for its enclosing folder
          Name is Folder X
     Move to Folder B


I have this repeated for 8 folders and files are moving flawlessly to their correct target locations.

Re: Moving files based on sub-folder name (multiple sub-fold

PostPosted: Tue Jan 10, 2023 10:54 am
by Mr_Noodle
Good to hear. You may want to check out Hazel's table functionality. It might be possible to consolidate those to one rule.