|I doubt the script will have a noticeable impact on your computer no matter how long you run it. You can replace the ping command with a timeout command:|
timeout /t <seconds> > nul
Also, I think you'd have to use
TaskList /nh /fi "IMAGENAME eq program.exe" | find "program.exe" 2>&1 >nul
If you wanna exit the current script, there's a command for that too instead of using taskkill:
Marking answers that solve, or help helps you solve a problem as "Best Answer" also helps other people solve similiar ones in the future.
message edited by RainBawZ