You are not logged in.
Pages: 1
Hello All,
in the below code how should i include the
return code for failure and success. i want the condition to be success if the file does not exist and exit. if the file exists it should be a failure and execute the MOVE command.
--------------
if exist "c:\test\file.ext"
move/y "C:\test\file.ext" "C:\quality\"
if not exist "c:\test\file.ext"
Offline
from the examples on
http://ss64.com/nt/if.html
IF EXIST C:\install.log (echo Installation complete) ELSE (echo The Installation failed)
so that becomes
IF EXIST "c:\test\file.ext" (move /y "C:\test\file.ext" "C:\quality\" ) ELSE (goto :eof)
Offline
Pages: 1