Batch program for natural to 7-digit file name conversion? (Miscellaneous)
> @ECHO OFF
> REM Batch file 00RENAME June 9, 2017 by Tom E., renames files using natural
> REM numbers as names (1, 2 ... 999999) to file names with leading zeroes
> REM (0000001, 0000002 ... 0999999). Helps to overcome different ordering
> REM conventions when transferring data from one program to another. Caution:
> REM in the current directory, any file without an extension will be renamed.
> FOR %%i IN (?) DO ren %%i 0%%i
> FOR %%i IN (??) DO ren %%i 0%%i
> FOR %%i IN (???) DO ren %%i 0%%i
> FOR %%i IN (????) DO ren %%i 0%%i
> FOR %%i IN (?????) DO ren %%i 0%%i
> FOR %%i IN (??????) DO ren %%i 0%%i
> FOR %%i IN (???????) DO ren %%i 0%%i
> ECHO ON
Works perfectly, Tom, thank you!
In this particular case, it is even unnecessary to move index and tag
files into another directory: they use file extensions and your batch thus
doesn't affect them (folder's contents must be re-indexed later, anyway).
Regards, Torsten
Complete thread:
- Batch program for natural to 7-digit file name conversion? - Torsten, 09.06.2017, 11:23 (Miscellaneous)
- Batch program for natural to 7-digit file name conversion? - tom, 09.06.2017, 13:02
- Batch program for natural to 7-digit file name conversion? - Torsten, 28.06.2017, 13:29
- Batch program for natural to 7-digit file name conversion? - tom, 09.06.2017, 13:02