Rename in batch file

Clone CLONE
May 31, 2010 at 15:14:35
Specs: Windows 7 Ultimate 32 bit, 3 GHz / 1919 MB
(I wish to auito9maticlly rename a backup file to include the current date. The following script is what I have tried.

SET LOCAL
cd /d D:\Images
dir
if exist MyBackup rename D:\Images\ MyBackup: "%date:/=.%"
pause
exit

The pause and dir commands are i\n there for troubleshootring.
The backup MyBackup.tib is in folder Images On drive D:. I have tried easter-egging different arrangements but have had no luck.
The file MyBackup.tib does, in fact,exist in folder D:\Images\

William Lockie


See More: Rename in batch file

Report •

#1
May 31, 2010 at 16:37:28
For more help this should be posted here:

http://www.computing.net/forum/prog...


Report •
Related Solutions


Ask Question