views:

114

answers:

2

I want to know if a process is running in the current machine as a part of my application ,but my application is deployed in another machine.

I'm using System.Diagnostics.Getprocessbyname but it looks for processes on the machine the application is deployed to. I want to know whether the process is running on my machine.

Is there a way to do this?

Note: This is edited by someone other than the question asker in an attempt to make it easier to understand. I have may not correctly captured their question..

A: 

ProcessMonitor is your friend.

Mitch Wheat
It looks like he wants to remotely look at processes programatically. I don't think Process Monitor is going to help him here.
SCdF
...but he doesn't actually say he wants to do it programmatically
Mitch Wheat
"as part of my application" -- I think he means as a function / feature of the application he is writing and judging by his tags it looks like some kind of web app.
SCdF
+2  A: 

You can use

System.Diagnostics.Process.GetProcessesByName("processname", "mymachine");
Igal Serban