Page 1 of 1

Cannot change directory names using RegEx but works on files

PostPosted: Fri Nov 11, 2016 5:01 pm
by keithslarke
I am using the following ^(.*)(\d{4})$ command in RegEx(1) to collect 4 numbers from a directory name and file names and move them around using, replace (\2)(\1)

The problem is that is appears to work fine on files but will not work on directory names.

I am able to change the directory names by using the replace "-" with "@" for example using replace(3) command on BRU but the RegEx(1) command will only work on file names.

all other boxes are the default values from installation.

Please can you help I am sure I am missing some small option.

Thanks

Keith.

Re: Can not change directory names using RegEx but worksOn Files

PostPosted: Sat Nov 12, 2016 2:28 am
by Emerkamp
Hello:
Sections (12), Folders is ticked.

Can you use \d\d\d\d instaead, for the 4 numbers
Maybe an example name will help.

Re: Can not change directory names using RegEx but worksOn Files

PostPosted: Sat Nov 12, 2016 3:12 am
by KenP
RegEx works on files and folders, so if both the files and folders have 4 digits at the very end of the name (excluding the file extensions) and you have the folders and files selected your code should work.

As the previous poster said it would be helpful if you could post examples of both the file names and the folder names.