Hello, i have the following batch file, which terminates the iTunes program so, that if i connect my iPod, it's not going to sync it. (I know you can set this up in iTunes.)
@echo off
:kill
cls
taskkill /F /IM itunes.exe >nul
if %errorlevel%==1 {
echo iTunes not found.
} else {
echo iTunes is killed.
}
goto kill
However, the >nul
does not respond to the command; so it just gives the default command text. So yeah, what i want to do:
If iTunes is not found, as given by the command, it should display
iTunes not found
If it is found and terminated,
iTunes is killed
Help? the errorlevel's don't work, this seem to be the fault of the nul
not working.