Run exe on LAN machine

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

Guest

Please tell me how i can run .exe file on a LAN machine. I have
administrative permissions. I am using C#.NET
 
On your machine, Control Panel/Administration Tools, there are 2 tools
for you to change code-access permissions.
The easiest way is using "Microsoft .NET Framework 1.1 Wizards/Trust an
assembly", browse to the exe on the LAN, and increase level of trust.
You may need to trust its dependencies also. "The Microsoft .NET
Framework 1.1 Configuration" provide finer grained configuration, but
requires some knowledge of code acess security.

Thi
 
Thanks Thi

I think i did'nt explain well. The exe file is not a .net exe. this is c++
unmanaged exe or it may be notepad.exe. what code i will write in C# in order
to run notepad.exe or any exe on LAN machine.
Thanks again for your replay.
 
I don't think there is any different lauching a exe on LAN or local.
Use Process class:
Process p = new Process();
p.StartInfo.FileName = @"\\machine\share\notepad.exe";
p.Start();

Hope it helps,
Thi
 
Actually, I think the OP want to run an EXE on a computer on local network.

There is two way I can think of:
1) your EXE is running under a Windows Service wrapper that have been
installed on the remote machine. So you can use "sc" command or
"ServiceController" class to control it remotely.
2) If the remote computer is running "REXEC" service(i.e. the Winsock
REXEC), you can use "rexec" command to execute the program.

Both methods require you to login as a valid user/run with identity of valid
user on the remote machine.
 
Back
Top