Hello Experts,
When accessing the asp.net application i am getting this following message.
basically i am invoking excel application.
I am using Microsoft Excel 11.0 Object Library.
Also i did the following:
1) in the web.config file i did <identity impersonate="true"/>
2) for my application folder i gave the asp.net account permission.
Still i am getting this error if i try to access the excel code. can anyone help me out.
--------------------------
----------
----------
----------
----------
----------
----------
----------
----------
-
Server Error in '/OACallListStage' Application.
--------------------------
----------
----------
----------
----------
----------
----
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.UnauthorizedAccessE
xception: 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.
Source Error:
Line 476: Next
Line 477:
Line 478: Dim oExcel As New Excel.Application
Line 479: Dim oBook As Excel.Workbook = oExcel.Workbooks.Add
Line 480: Dim oSheet As Excel.Worksheet = oExcel.ActiveSheet
Source File: c:\inetpub\wwwroot\OACallL
ist\ExcelE
xport.aspx
.vb Line: 478
Start Free Trial