views:

92

answers:

1

Hello,

I need to find out is Process is running on remote machine or not, I know process id and remote pc ip. How to do that? I have tried code below but do not find way to pass credentials to login to remote machine. Using code below I get access denied as expected.

Process engineProcess = Process.GetProcessById(PID, IP);

Regards, Tomas

+1  A: 

One way you could try it by changing the Identity of current thread by impersonating. here is an example of how to implement such:

http://support.microsoft.com/kb/306158

look under the section "Impersonate a Specific User in Code"

coderguy123