Active Process Enumeration using C#

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi

I Wonder... How can I enumerate the active process using c#?
what is the ToolHelp32*.* C# equivalent?
What is the 'Process32First/Next' equivalent

Nadav.
 
Nadav,

Use the following code to enumerate the active processes on a
computer

Process[] running = Process.GetProcesses();
foreach(Process p in running)
Console.WriteLine(p.ProcessName);

If you specify a computer name in the GetProcesses() method, you
can retreive from a network location.

HTH,

//Andreas
 
Back
Top