MSOffice and ASP.NET

Discussion in 'ASP .Net' started by S.Kartikeyan, Mar 4, 2004.

  1. S.Kartikeyan

    S.Kartikeyan Guest

    Hello,

    I have a ASP.NET Page which allows the user to upload a file.
    What i have to do is
    when the user uploads a PowerPointFile i have to convert in to html
    and
    save both ppt and html versions of it.

    I have a working program of converting ppt to html on localmachine.
    When I try to do it from the ASP.NET Page I get an error Access
    Denied.

    Regarding Access to the directory i am able to save the posted file
    (ppt)to the
    directory.only when i convert it to html and save i get the problem.

    Here are the details.
    ----------------------------------------------------------------------------
    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
    -----------------------------------------------------------------------------
    In the source Error sections of ASP.NET error page i have the first
    line of the
    function where i am creating the PowerPoint.ApplicationClass() causing
    the problem.


    Is the problem due to desktop access to the powerpoint application.
    How to fix the problem.
    OR
    Does the MSOffice components work only with the standalone
    applications.



    S.Kartikeyan
     
    S.Kartikeyan, Mar 4, 2004
    #1
    1. Advertising

  2. S.Kartikeyan

    Paul Glavich Guest

    There are probably 2 aspects to it.

    1. You are trying to interop within ASP.NET and the security policy may
    prohibit this.
    2. The loading and conversion using powerpoint will probably require access
    to other directories, and possibly generate some temporary files somewhere.
    You may need to grant additional access to some directories (and I am not
    sure which ones) for the aspnet user (Win2000) or NETWORK SERVICE (Win2003)
    to make it work. Check powerpoint for some temp directories that are setup
    within the program or see where it might be creating temporary files under
    your known working user.


    --
    - Paul Glavich


    "S.Kartikeyan" <> wrote in message
    news:...
    > Hello,
    >
    > I have a ASP.NET Page which allows the user to upload a file.
    > What i have to do is
    > when the user uploads a PowerPointFile i have to convert in to html
    > and
    > save both ppt and html versions of it.
    >
    > I have a working program of converting ppt to html on localmachine.
    > When I try to do it from the ASP.NET Page I get an error Access
    > Denied.
    >
    > Regarding Access to the directory i am able to save the posted file
    > (ppt)to the
    > directory.only when i convert it to html and save i get the problem.
    >
    > Here are the details.
    > --------------------------------------------------------------------------

    --
    > 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
    > --------------------------------------------------------------------------

    ---
    > In the source Error sections of ASP.NET error page i have the first
    > line of the
    > function where i am creating the PowerPoint.ApplicationClass() causing
    > the problem.
    >
    >
    > Is the problem due to desktop access to the powerpoint application.
    > How to fix the problem.
    > OR
    > Does the MSOffice components work only with the standalone
    > applications.
    >
    >
    >
    > S.Kartikeyan
     
    Paul Glavich, Mar 4, 2004
    #2
    1. Advertising

  3. Also, it should be noted that unattended server side use of Microsoft Office
    in this manner is not a supported scenario.

    --
    Thanks,

    Eric Lawrence
    Program Manager
    Assistance and Worldwide Services

    This posting is provided "AS IS" with no warranties, and confers no rights.

    "Paul Glavich" <-NOSPAM> wrote in message
    news:#...
    > There are probably 2 aspects to it.
    >
    > 1. You are trying to interop within ASP.NET and the security policy may
    > prohibit this.
    > 2. The loading and conversion using powerpoint will probably require

    access
    > to other directories, and possibly generate some temporary files

    somewhere.
    > You may need to grant additional access to some directories (and I am not
    > sure which ones) for the aspnet user (Win2000) or NETWORK SERVICE

    (Win2003)
    > to make it work. Check powerpoint for some temp directories that are setup
    > within the program or see where it might be creating temporary files under
    > your known working user.
    >
    >
    > --
    > - Paul Glavich
    >
    >
    > "S.Kartikeyan" <> wrote in message
    > news:...
    > > Hello,
    > >
    > > I have a ASP.NET Page which allows the user to upload a file.
    > > What i have to do is
    > > when the user uploads a PowerPointFile i have to convert in to html
    > > and
    > > save both ppt and html versions of it.
    > >
    > > I have a working program of converting ppt to html on localmachine.
    > > When I try to do it from the ASP.NET Page I get an error Access
    > > Denied.
    > >
    > > Regarding Access to the directory i am able to save the posted file
    > > (ppt)to the
    > > directory.only when i convert it to html and save i get the problem.
    > >
    > > Here are the details.

    >
    > --------------------------------------------------------------------------
    > --
    > > 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

    >
    > --------------------------------------------------------------------------
    > ---
    > > In the source Error sections of ASP.NET error page i have the first
    > > line of the
    > > function where i am creating the PowerPoint.ApplicationClass() causing
    > > the problem.
    > >
    > >
    > > Is the problem due to desktop access to the powerpoint application.
    > > How to fix the problem.
    > > OR
    > > Does the MSOffice components work only with the standalone
    > > applications.
    > >
    > >
    > >
    > > S.Kartikeyan

    >
    >
     
    Eric Lawrence [MSFT], Mar 4, 2004
    #3
  4. S.Kartikeyan

    S.Kartikeyan Guest

    How to change the Interop security policy so that it can be done.
    I don't think it uses temporary files.

    >There are probably 2 aspects to it.
    >1. You are trying to interop within ASP.NET and the security policy may
    >prohibit this.

    --
    - Paul Glavich

    You mean it is impossible to do it.????????
    Or
    just the official documentation does not list the scenario,but the scenario is
    possible


    >Also, it should be noted that unattended server side use of Microsoft Office
    >in this manner is not a supported scenario.


    --
    >Thanks,


    >Eric Lawrence
    >Program Manager
    >Assistance and Worldwide Services
     
    S.Kartikeyan, Mar 5, 2004
    #4
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. steven chong

    MSOffice Programming (Word) help

    steven chong, Oct 1, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    567
    Cindy Meister -WordMVP-
    Oct 3, 2003
  2. steven chong

    MSOffice Programming (Word) help

    steven chong, Oct 1, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    418
    Cindy Meister -WordMVP-
    Oct 3, 2003
  3. MSoffice metadata

    , Jun 25, 2006, in forum: Python
    Replies:
    3
    Views:
    411
    Roger Upole
    Jun 27, 2006
  4. Amelyan
    Replies:
    2
    Views:
    199
    Amelyan
    Apr 25, 2005
  5. srinivas
    Replies:
    1
    Views:
    90
Loading...

Share This Page