windows 7 batch script- if statement not working -
cd c:\users\user1\desktop if "%time:~0,1%" == " " ren 85.txt %time:~1,1%.txt else ren 85.txt %time:~o,1%.txt pause
the script above not working, if put following line file:
ren 85.txt %time:~1,1%.txt
it working.
why if...else
statement above not working?
o
doesn't work, try 0
(zero):
cd c:\users\user1\desktop if "%time:~0,1%"==" " (ren 85.txt %time:~1,1%.txt ) else ren 85.txt %time:~0,1%.txt pause
Comments
Post a Comment