I have a batch file that moves a file. I'm testing it and have got an access denied error which I can fix easily, however I've noticed that the errorlevel for this issue is still 0.
I would expect the value to be higher than that. Any ideas?
move /Y "C:\TestNoPersmissions" "E:\somedestination"
echo %errorlevel%
if errorlevel 1 goto Failure
if errorlevel 0 goto Success
:Failure
eventcreate /t error /id 100 /so TestMove /l application /d "Move product XML failure"
echo Error!
:Success
echo "Success"
pause