how to excute exe

Y

Yoshitha

Hi
i've one exe ( got through vb.net) and i want to execute this exe file
through my asp.net application and i wrote the following lines of code in
the button click event to run the exe but when i click on button it is not
running that exe i've given

shell("E:/project/windowsapplication1.exe",AppWinStyle.NormalNoFocus) ( i
wrote this statement in webform)

Can anubody tell me how to solve this problem.

Thanx in advance
Yoshitha
 
L

Lau Lei Cheong

ASP.NET application default runs in ASPNET/Network Service account which
does not have rights to execute files.

You should impersonate to another account in order to run it.
 
S

Steve B.

Most of time, it is a bad idea to run exe from ASP.Net web pages.

If possible, try to convert the app into class library or even com object.
The ASP.Net execution won't "click" for you...

Your sample make me think you are trying to execute the app on the CLIENT
side.
Is it rigth ? If yes you should realy think about other way since IE or
other browsers run in a sandbox environment...

Steve
 
J

Juan T. Llibre

That looks like VB.NET, but that syntax should only
work in a Windows form.

To run an exe from a web form, you normally use Process.Start
 
E

Eliyahu Goldin

shell("E:/project/windowsapplication1.exe",AppWinStyle.NormalNoFocus) ( i
wrote this statement in webform)

What is this? What are you programming in?

Eliyahu
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,234
Latest member
SkyeWeems

Latest Threads

Top