6

I want to be able to close a process on a remote computer using a .bat file. eg: taskkill /im Myapp.exe

Is using taskkill a suitable way to close an application? eg like clicking the 'X' on the toolbar?

Does it give the app time to run all of it's closing down methods/destructors? Or does it cause it to end abruptly, losing any data that hasn't had a chance to be written before closing?

nf313743
  • 4,129
  • 8
  • 48
  • 63

1 Answers1

3

Yes, if you dont use /f.

pinichi
  • 2,199
  • 15
  • 17
  • 4
    According to the documentation http://technet.microsoft.com/en-us/library/bb491009.aspx it actually will always forcefully terminate a remote process. The /f switch is only for local processes. – juharr May 18 '11 at 12:01