You are not logged in.
I have filenames like this:
2018 12 02 - Quarterly Report A2.pdf
DOE, John - 2018 11 30 - Sales Statistics A33.pdf
DOE, Janet - 2018 04 02 - Products Recieved By Vendor A122 - Duplicate.xls
etc....
I need to put brackets around the 'A' numbers, and cannot figure out the logic.
I have thousands of files to rename....please help!
Thanks.
Offline
This kind of problem requires pattern matching, which can be achieved with either Regular Expressions or Pascal Script rule.
The following regular expression will do the job:
Expression: \b(A\d+)
Replace: ($1)
Input names:
2018 12 02 - Quarterly Report A2.pdf
DOE, John - 2018 11 30 - Sales Statistics A33.pdf
DOE, Janet - 2018 04 02 - Products Recieved By Vendor A122 - Duplicate.xls
Output names:
2018 12 02 - Quarterly Report (A2).pdf
DOE, John - 2018 11 30 - Sales Statistics (A33).pdf
DOE, Janet - 2018 04 02 - Products Recieved By Vendor (A122) - Duplicate.xls
Here is the documentation for the regular expressions:
http://www.den4b.com/wiki/ReNamer:Regular_Expressions
Offline
That works perfectly, den4b. Thanks!
I manually renamed a bunch of files prior to your response. Other than unmarking the individual files, is there a way to incorporate ignoring already bracketed files using the regular expressions so I don't end up with double brackets?
Offline
is there a way to incorporate ignoring already bracketed files using the regular expressions so I don't end up with double brackets?
Yes, but the expression will get a bit more complicated:
Expression: (\A|[^(])\b(A\d+)
Replace: $1($2)
Alternatively, you can use a Replace rule to replace double brackets "((" and "))" with a single bracket "(" and ")".
Offline
Thanks, again, den4b. I must say that I am most impressed with your utility, and your quick response. So much so, that I am going to purchase your software right now! Thanks, again.
Offline