Listar los procesos del sistema

por Admin el 9/3/2009 8:47:00 PM

El namespace Windows.Diagnostics nos ofrece una forma muy sencilla de listar los procesos que se están ejecutando en una maquina, al estilo “Administrador de Windows”.

Process[] myProcesses = Process.GetProcesses();
foreach (Process p in myProcesses)
{

string sVersion = "";
try

    sVersion = p.MainModule.FileVersionInfo.FileVersion;
}
catch { }
Console.Write { p.ProcessName, p.Id.ToString(), sVersion );


}

Comments

3/17/2010 7:56:34 AM

Bobby Ruedas

This is a very useful post, I was looking for this information. Just so you know I located your blog page when I was researching for blogs like mine, so please check out my site sometime and leave me a comment to let me know what you think.

Bobby Ruedas United States

Add comment




  Country flag

biuquote
  • Comment
  • Preview
Loading