0

If I run my batch script as normal from cmd it seems to work fine.

What I'm trying to do is setup my script as a service using nssm. That seems to work as expected except for Taskkill - this isn't killing the desired application for some reason.

Anybody have some suggestions?

This is my taskkill code in my bat file:

TASKKILL /f /t /im "application.exe"
  • you cannot use taskkill to stop services. use `sc stop servicename` instead – elzooilogico Apr 14 '21 at 05:52
  • my bat file is a service - but the program it is launching and trying (but failing) to kill is a showing up as a background application, not a service (I checked by running net start and it is not listed) – CreativelyChris Apr 14 '21 at 16:02

0 Answers0