I have searched on this forum but not been able to recognize what I am looking for. IRC dosen't allow the DCC of the files having spaces. How to create a batch file which replace spaces with underscore for all the MP3/FLAC files in the folder. I tried this but failed
@echo off
Setlocal enabledelayedexpansion
Set "Pattern= "
Set "Replace=_"
For %%a in (*.mp3) Do (
Set "File=%%~a"
Ren "%%a" "!File:%Pattern%=%Replace%!"
)
Pause&Exit
It's giving me the error that the files are being used by another process though the files were not used by any programs and now it ain't doing anything whenever I run it it just says "press any key to continue and shuts down"
Any help? thanks.