0

If I try this command:

forfiles /M *.WAV /C "cmd /c rename @file temp.WAV"

I get this error :

a duplicate file name exist, or the file cannot be found

I want that like windows i can add to all the rest files that exist a number like that:

temp.WAV
temp (2).WAV
temp (3).WAV
temp (4).WAV
temp (5).WAV

I tried several time and method and didn't success:

forfiles /M *.WAV /C "cmd /c rename @file temp.WAV

a duplicate file name exist, or the file cannot be found

Andronicus
  • 25,419
  • 17
  • 47
  • 88
  • You can prefix your `cmd /C ...` with `echo ` to see how (and whether) the loop variable is being inserted. – YellowAfterlife Aug 04 '19 at 13:48
  • Possible duplicate of [Windows bat file to rename multiple files with custom names](https://stackoverflow.com/questions/38416981/windows-bat-file-to-rename-multiple-files-with-custom-names) – JosefZ Aug 04 '19 at 14:52

0 Answers0