0

I have the below command which run batch file, I need to run this batch when I open the ASPX page in the machine browser to affect the machine and not affect server :

ProcessStartInfo psi = new ProcessStartInfo(this.WhiteLabel.Text);
psi.RedirectStandardOutput = false;
psi.WindowStyle = ProcessWindowStyle.Hidden;
psi.UseShellExecute = true;
Process.Start(psi);
mason
  • 31,774
  • 10
  • 77
  • 121
  • Possible duplicate of [How to execute an application on the client from a website?](http://stackoverflow.com/questions/7814339/how-to-execute-an-application-on-the-client-from-a-website) – Jacob Oct 19 '15 at 01:01
  • Is this a public Internet site, or a company Intranet site? – mason Oct 19 '15 at 01:22

1 Answers1

2

This is not possible because of security concerns. The only possible way might be to create an ActiveX library that the user would acknowledge and accept on their browser to run. What are you trying to run on the client? Maybe there is another approach?

This has been asked before see here... How to execute an application on the client from a website?

Community
  • 1
  • 1
Ejaski
  • 199
  • 5
  • 10 machine, every machine will have web page will keep open to present some data, and in the background will call batch file to do connect to serial port ( they have internal application for that ) so i need to do that through web page – Ikrami Hall Oct 19 '15 at 01:13
  • Not sure using a web page in this manner is the best route. Maybe you can have a download link that will be used to download software and setup each machine with some kind of background service? Then background service could then send data back and forth from each machine to a central web service. – Ejaski Oct 19 '15 at 02:17