Hi, code to killtasks in taskmanager?

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
goofan
Posts: 8
Joined: 02 Dec 2009 03:50

Hi, code to killtasks in taskmanager?

#1 Post by goofan » 02 Dec 2009 04:21

Hi i need a small code that makes so that it opens the taskmanager(Ctrl+Alt+Del) or just runs it outside the taskmanager.
-however-
i wanna make so that i tell it to kill certain tasks in the taskmanager by just simply click the "KillTasks.bat"



-Thanks in advance
-Thomas

!k
Expert
Posts: 378
Joined: 17 Oct 2009 08:30
Location: Russia

#2 Post by !k » 02 Dec 2009 06:48

Code: Select all

taskkill /f /im explorer.exe

goofan
Posts: 8
Joined: 02 Dec 2009 03:50

#3 Post by goofan » 02 Dec 2009 06:52

Is there any other code needed? (im a very VERY big noob at batching)
or would that kill the task explorer.exe? (just to see if i got it right) :D thanks a bunch.
i can change the explorer.exe to whatever i want to kill any tasks? and just duplicate the code to kill more then one task? :D
-Thanks

!k
Expert
Posts: 378
Joined: 17 Oct 2009 08:30
Location: Russia

#4 Post by !k » 02 Dec 2009 07:59

kill more then one task:

Code: Select all

taskkill /f /im notepad.exe /im mspaint.exe /im calc.exe

for help run this code:

Code: Select all

cmd /k taskkill /?

and read text in black window

goofan
Posts: 8
Joined: 02 Dec 2009 03:50

#5 Post by goofan » 02 Dec 2009 11:06

ok thanks

Post Reply