3

Whenever I start my computer up, there are numerous programs running in the background that I usually don't need , which take up a decent amount of memory.

Is there a way to kill processes in a batch command so that I could save myself a lot of troubles and just run that batch command whenever I start my computer up?

Edit: Answers are saying how to prevent these programs from running. What I'm looking for is a batch command (if there is one) so I can use it for other personal reference.

4 Answers 4

9

You can disable programs that start with Windows in MSConfig. If you prefer to kill a process through batch file you can use the taskkill command:

taskkill /f /im processname.exe
1

In Windows 7, you can use "TASKKILL" which is built in, but you need to know the process ID. You'd get that from the Task manager, by clicking the Processes tab and then using View > Select Columns, and checkmarking PID. Or, you can kill by name.

From the Help file (which you can get to by opening a CMD window and typing "TASKKILL /?") some examples:

 TASKKILL /IM notepad.exe
 TASKKILL /PID 1230 /PID 1241 /PID 1253 /T
 TASKKILL /F /IM cmd.exe /T
 TASKKILL /F /FI "PID ge 1000" /FI "WINDOWTITLE ne untitle*"
 TASKKILL /F /FI "USERNAME eq NT AUTHORITY\SYSTEM" /IM notepad.exe
 TASKKILL /S system /U domain\username /FI "USERNAME ne NT*" /IM *
 TASKKILL /S system /U username /P password /FI "IMAGENAME eq note*"

However, I'm with the other answers -- I can't imagine why you'd want to go through the hassles of killing processes instead of just keeping them from starting in the first place.

0

There's a few options - natively there's taskill in my windows 8 install, but not my windows 7 install - you can use the /IM switch to kill tasks with specific names.

If you don't have taskill available, you can use pskill from system internals

-1

You need the task at start up. Like i have a touch screen windows based all in one PC. If i stop the handwriting app from starting at start up I lose it. However, the handwriting app is not compatible with DX9 audio file dll. So if I use @echo off, taskkill blah blah blah and start said program that needs dx9 audio dll, exit then that becomes my shortcut for the program.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .