Rename file based on Folder name with tokens

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

I'd like to rename my files based on what folder they reside. But, If I could use a token I wouldn't have to hardcode each rule for each folder. Can I use a token to check the current containing folder's name?

I'd like to check to see if the name already matches if the file doesn't match change it, if it does match ignore it.
joshsmith01
 
Posts: 6
Joined: Tue Aug 16, 2011 2:50 pm

You can use a nested condition (hold down option key while clicking the + button). Once you have that you can set it up like this:
Code: Select all
If (all) match
    If (all) match for (the enclosing folder)
        Name matches (• parent name)
    Name matches (•parent name)

Here, parent name matches (anything) so it will just store the whole name into that attribute. When a custom attribute is re-used, if it was already matched, it will require you to match the value it captured before. So in this case what this does is require that the current file has the same name as its parent folder.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support