Results 1 to 2 of 2

Thread: System.UnauthorizedAccessException Errors with Excel Interop

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 2001
    Location
    Chicago, IL
    Posts
    49

    System.UnauthorizedAccessException Errors with Excel Interop

    Hello everyone..

    Im trying to use the Excel 10.0 COM interop stuff to send an excel spreadsheet dynamicly created based on the sql query.

    Here is a code snippet where things start going wrong :

    Code:
    Dim xlApp As New Excel.ApplicationClass()
    And here is the actual error..


    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.

    The ASP.NET process is not authorized to access the requested resource. For security reasons the default ASP.NET process identity is '{machinename}\ASPNET', which has limited privileges. Consider granting access rights to the resource to the ASP.NET process identity.

    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 "{machinename}\ASPNET" user. Highlight the ASP.NET account, and check the Write box in the Allow column.
    These are the steps I have taken so far..

    1. Checked Excel was installed and the version matches
    2. Given full security to ASPNET for that machine to the entire web folder.
    3. Checked the security of ASPNET to ensure its got administrator privelages.

    I have searched around on the net and found multiple instances of posts like this but no real responses.

    Any help would be great.

    Thanks in advance,

    - Darren

  2. #2

    Thread Starter
    Member
    Join Date
    Dec 2001
    Location
    Chicago, IL
    Posts
    49
    Nobody has experience with this issue? its holing up a huge project

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width