Currently, I have this command in a .bat file:
taskkill /im process.exe /f /tHowever, I would like it to kill process.exe for any and every user who is currently logged in on Windows 10. Is there a way to achieve this? I can only find solutions that pertain to specific users.
I simply want to kill every instance of this process regardless of which user is running it.
I have also tried inserting a wildcard in for username like this, but this doesn't kill any of the processes at all.
22 Answers
Run taskkill /im process.exe /f /t as Administrator.
If you include that command in a .bat file (batch script), you can run the .bat file as an Administrator by:
- Create a shortcut for the .bat file
- Right-click the shortcut and select properties
- In the shortcut tab select "Advanced"
- Select "Run as administrator" and click OK
Your command is correct. But you need to open a cmd as administrator first. Open Start, find Command Prompt, right click, open as administrator.
taskkill /im process.exe /f /t 5