How to Close Multiple PC Programs with a Batch File

How to Close Multiple PC Programs with a Batch File

Closing multiple PC programs with a batch file requires you to know mostly about the command "taskkill". It is not quite hard and you can learn to do it yourself in about 5 minutes!

Steps

Image titled Close Multiple PC Programs with a Batch File Step 1
1
Open Notepad or Notepad++. Close all programs except your web browser that contains this page and Notepad or Notepad++.
Image titled Close Multiple PC Programs with a Batch File Step 2
2
Type @echo off and then hit ↵ Enter.
Image titled Close Multiple PC Programs with a Batch File Step 3
3
Type cls and then hit ↵ Enter.
Image titled Close Multiple PC Programs with a Batch File Step 4
4
Type taskkill /IM your-program-name.your-program-extension /T /F and then hit ↵ Enter.
Image titled Close Multiple PC Programs with a Batch File Step 5
5
Repeat this command for as many programs as you want!
Image titled Close Multiple PC Programs with a Batch File Step 6
6
When finished, type exit on the last line and hit ↵ Enter.
Image titled Close Multiple PC Programs with a Batch File Step 7
7
Click File > Save As. Change the Save as type to all files in Notepad; in Notepad++ change to batch file. In Notepad, select all of the filename and delete it and replace it with your-preferred-program-name.bat. In Notepad++, you'll see that the extension is already .bat so only change the part before .bat to your preferred program name.
Image titled Close Multiple PC Programs with a Batch File Step 8
8
Select your preferred saving directory at the top and when finished, click Save.
Image titled Close Multiple PC Programs with a Batch File Step 9
9
Check your work by running the batch. Look in the task manager ( Ctrl+Alt+Delete) to see if the program doesn't exist there anymore. If the program does exist, edit your batch program by right clicking at the program and clicking edit. Check that you follow the instructions correctly. If the program doesn't exist, well done! You have completed this how-to!
Advertisement