How to Invoke IExplorer from aspx page

K

kapila Wijethilaka

Hello,

I want to invoke clients iExplorer from my axpx page.
I did a some cod eto dot this.but it gave me below error.

can anybody help me with this

thanks

Access is denied.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.UnauthorizedAccessException: Access is denied.

ASP.NET is not authorized to access the requested resource. Consider
granting access rights to the resource to the ASP.NET request identity.
ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or
Network Service on IIS 6) that is used if the application is not
impersonating. If the application is impersonating via <identity
impersonate="true"/>, the identity will be the anonymous user (typically
IUSR_MACHINENAME) or the authenticated request user.

To grant ASP.NET write access to a file, right-click the file in Explorer,
choose "Properties" and select the Security tab. Click "Add" to add the
appropriate user or group. Highlight the ASP.NET account, and check the
boxes for the desired access.

This my code segment

Browser = new InternetExplorer(); //the error gave at this point

Browser.Visible = true;

Browser.GoHome();

procs = Process.GetProcessesByName("IEXPLORE");
 
C

Chris Jackson

You are not invoking IE on the client - the code behind runs on the server,
and you are trying to launch an IE process on the server. You can set up
permissions to allow this, but you will won't get what you want. Rather, you
need to run client-side code. Since your JavaScript code runs in a sandbox,
it isn't going to be able to launch processes. However, since you already
are running in a browser, just use a JavaScript window.open to launch a
second browser window.
 
T

Tommy

If you want to launch a new instance of "Internet Explorer" on the
client side, you will need to use javascript, or a component that is
downloaded on the client's machine.

The code you provided attempts to launch "Internet Explorer" on the
web server, and that's why you are getting access denied error. Even
if you have enough permission to launch IE on the web server, it is
certainly not what you're looking for.

With javascript, you can use the "ActiveXObject" method to launch an
executable.

It'll be helpful if you can explain why you want to launch a new
instance of "Internet Explorer" on the client side.

Tommy,
 

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,769
Messages
2,569,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top