- If you know the name of a process to kill, for example notepad.exe, use the following command from a command prompt to end that process:
Above Code Will terminate Program Normally. If there is some unsaved data then it will ask about confirmation before termination.
- Now if you want to kill that process forcefully and not want to ask confirmation before termination then just add /F to previous command. For example to kill notepad.exe code will be:
- If you know the Process ID of task then to kill that task, we use taskkill /PID [Process ID]. For example if PID is 8888 then command will be: