how do i Kill a running process in Memory, which maybe or may not be visible in Task Manager.
Printable View
how do i Kill a running process in Memory, which maybe or may not be visible in Task Manager.
To kill all Notepad instances for example...
VB Code:
System.Diagnostics.Process.Start("Notepad.exe") Dim oProcess As Process For Each oProcess In System.Diagnostics.Process.GetProcessesByName("NOTEPAD") oProcess.Kill() Next
Well quite right... but this supposedly will kill only the Process which i have started, i want to get a list of Process currently residing in the memory and then kill a few particular ones from them. Is it possible ?
:)VB Code:
Dim oProcess As Process For Each oProcess In System.Diagnostics.Process.GetProcesses() If oProcess.ProcessName.ToString = "YourDesiredExe" Then oProcess.Kill() End If Next
My previous code will get the process you desire and does not have to be created by you or your code.
gr8 ! dat did it
Thanks.
Ps, Resolve your thread from the thread tools manu as editing the last post will not show at the thread level view. ;)