Hi,
By using C# we can find whether a particular process is running or not.
We can use System.Diagnostics.Process class.
The scenario of finding a running process may come in Windows application development.
Let us consider In My machine, ABC.exe is running. And I have to check that whether it is running or not. Just call the below method with "ABC" as argument.
private bool IsProcessRunning(string sProcessName)
{
System.Diagnostics.Process[] proc = System.Diagnostics.Process.GetProcessesByName(sProcessName);
if (proc.Length > 0)
return true;
else
return false;
}
Thanks
PMM :)