When a program does not respond and clicking on the cross at the top right does not close, it is necessary to force the program to close.
One way to do this is to eliminate the process linked to the program.
A process is an ongoing program. It is an active entity that performs all the tasks of a program. For example, when you start Word, a process is created to perform the tasks of the Word program.
If you open another Word window, a new process will be created. Each process running in Windows is assigned a unique number called a Process ID or PID.
When you close a process, you will automatically force the closure of the program to which it is linked.
In this tutorial we will see how to close or remove the process of a locked program that does not respond and refuses to close.
Forcing a program to close can also be useful when a program is abnormally using a high percentage of resources (CPU, RAM): removing the program-related process will free up system resources and speed up Windows.
Forcing a Program to Close in Windows
Using the Task Manager
To delete a process (and force a program to close) with the Task Manager, follow these instructions:
Open Task Manager.
- In the Process tab, select the program whose closure you want to force.
- Click on the Finish Job button at the bottom right of the window to force the program to close.
- You can also right-click on the program and select “End of task”.
- Alternatively, go to the Details tab, select the program you want to close
- Click on the End Task button.
Click Stop the process to force the program to close.
Close a Program through the Command Line
To close a process, follow these instructions:
- Open the command line.
- Enter the task list to see a list of all running processes. Note the name of the image and the PID of the process (e.g. WINWORD.exe / 25484) you want to delete.
- You can filter the processes with findstr :
Eliminate the process with taskkill by specifying the name of the image:
Use the PowerShell
To remove a process with PowerShell (and force a program to stop), follow these instructions:
- Open PowerShell.
- Enter ps to see a list of all running processes. Enter the name and identification of the process (e.g. WINWORD.exe / 7672) you want to delete.
- You can filter the processes this way:
- Remove the process with Stop-Process by specifying the name of the process: Stop-Process -Name “WINWORD” -Force
- You can also use the process identification: Stop-Process -ID 7672 -Force