I am trying to rename all the files present in a Windows directory using FOR command as follows at the command prompt:
for %1 in (*.*) do ren %1 test%1
E.g. This renames a file enc1.ctl to testenc1.ctl enc2.ctl to testenc2.ctl
Thats not what i want. What i want is enc1.ctl renamed to test1.ctl enc2.ctl renamed to test2.ctl
How do i do that?
@Akelunuk: Thanks, that w kind of works but i have files names as
h263_enc_random_pixels_1.ctl , h263_enc_random_pixels_2.ctl which i want to rename to
test1.ctl and test2.ctl respectively
Then how?
If you know the number of files, (say 10), you can use