What exactly is image name? For example,
tasklist /FI "IMAGENAME eq myapp.exe" 2>NUL | find /I /N "myapp.exe">NUL
if "%ERRORLEVEL%"=="0" echo Programm is runningI googled can't seem to find its definition anywhere. Why is it called image name?
1 Answer
Image name is the name of the executable, e.g. explorer.exe or myapp.exe, so you're already using it correctly. /FI is similar to find, so find is only useful if you need the errorlevel.