vixenfinder wrote:Okay so I'm working trying to develop my first batch file and some of the folders have a comma and I'm trying to replace the comma with a space hyphen. I'm not sure if I have my batch script right
- Code: Select all
CALL "C:\Program Files\Bulk Rename Utility\Bulk Rename Command\BRC32.exe" /DIR:"C:\Users\Etc.\Etc.\Etc.\Etc.\" /RECURSIVE /NOFILES /REPLACECI:",":" -" /REPLACECI:"(www.website.com)":"[website]" /EXECUTE
Furthermore, does anyone know of a command line that can search through my subfolders and delete files with a specific name?
EDIT: Okay; I've managed to figure out the comma replacing with space hyphen issue but now I'm having issues with the file names with Parenthesis around them. Eg: example_(http://www.website.com).zip TO example_[website].zip and I can't seem to get the command right for that. Any ideas?
P.S.: Those who want to follow up on the batch command deleting specific files; well the answer is
- Code: Select all
DEL <filepath> *filename*.* /S /Q
man,
YOU have solved MY problem!!!!!i can't understand from the hel file that in the replaceci i can use the " <-- !!!
So vixenfinder, I HAVE yo help you!!!
I have a problem with this colon (":") ... i think it's impossible to find out a http:// ... nor the slash or backslash are allowed chars, neither colon are accepted characters.
So, given that your scenario couldn't contain these chars, I think something like
[blahblah] /REPLACECI:"(www.":"[" /REPLACECI:")":"]" /EXECUTE
could help.
you can't expect what TLD you'll find (.org, .com, .net, .uk, .de ...) ... but if you want, you can list the most found in your experience and add as much
/REPLACECI:".TLD)":"]" as you want

Or if you're skilled with regexp... you can do what you want, select what you want ... it's great. But i'm not the right person to teach you something with regex, for now.
I hope to help you as much as YOU helped me...
... let me explain: i don't knew that the "replaceci" switch accepted parameters between quotes! But reading your example i've understand that's possible!
In that way i can eradicate all the spaces in my f*** directories!

good bye!