473,386 Members | 1,621 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Error Message: ASP.NET not authorized to access the requested reso

Attempting to access outlook from C# .NET ASP app. Have added reference to
COM Microsoft Outlook 11 Object Library. Have included

using System.Runtime.InteropServices;
using System.Web.Mail;
using Microsoft.Office;
using Microsoft.Office.Interop;
using Microsoft.Office.Interop.Outlook;
using Microsoft.Office.Core;

When I run, it compiles but I get runtime error: 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.

Line 72: Application outlookApp = new Application();

I granted write access for ASPNET to Program files\Microsoft
Office\Office11\msoutl.olb

Any clues where to start? AProchko
Jul 21 '05 #1
2 6728
Have you seen the article entitled "Considerations for Server-Side
Automation of Office"?
http://support.microsoft.com/default...;en-us;Q257757

"Microsoft does not currently recommend, and does not support, Automation of
Microsoft Office applications from any unattended, non-interactive client
application or component (including ASP, DCOM, and NT Services), because
Office may exhibit unstable behavior and/or deadlock when run in this
environment."

-Dino
"Aprochko" <Ap******@discussions.microsoft.com> wrote in message
news:08**********************************@microsof t.com...
Attempting to access outlook from C# .NET ASP app. Have added reference
to
COM Microsoft Outlook 11 Object Library. Have included

using System.Runtime.InteropServices;
using System.Web.Mail;
using Microsoft.Office;
using Microsoft.Office.Interop;
using Microsoft.Office.Interop.Outlook;
using Microsoft.Office.Core;

When I run, it compiles but I get runtime error: 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.

Line 72: Application outlookApp = new Application();

I granted write access for ASPNET to Program files\Microsoft
Office\Office11\msoutl.olb

Any clues where to start? AProchko

Jul 21 '05 #2
I was following the MSDN Library example:
An Introduction to Programming Outlook 2003 Using C#

Are you suggesting not to attempt this?

"Dino Chiesa [Microsoft]" wrote:
Have you seen the article entitled "Considerations for Server-Side
Automation of Office"?
http://support.microsoft.com/default...;en-us;Q257757

"Microsoft does not currently recommend, and does not support, Automation of
Microsoft Office applications from any unattended, non-interactive client
application or component (including ASP, DCOM, and NT Services), because
Office may exhibit unstable behavior and/or deadlock when run in this
environment."

-Dino
"Aprochko" <Ap******@discussions.microsoft.com> wrote in message
news:08**********************************@microsof t.com...
Attempting to access outlook from C# .NET ASP app. Have added reference
to
COM Microsoft Outlook 11 Object Library. Have included

using System.Runtime.InteropServices;
using System.Web.Mail;
using Microsoft.Office;
using Microsoft.Office.Interop;
using Microsoft.Office.Interop.Outlook;
using Microsoft.Office.Core;

When I run, it compiles but I get runtime error: 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.

Line 72: Application outlookApp = new Application();

I granted write access for ASPNET to Program files\Microsoft
Office\Office11\msoutl.olb

Any clues where to start? AProchko


Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: AlexB | last post by:
The ASP.NET account needs access to the following directory: C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322 \Temporary ASP.NET Files Locate the folder in Windows Explorer, right-click on the...
2
by: Ramesh | last post by:
hi, I have created COM when i try to use that instance in C#.net Wep application i am getting following error message. DBUsingCom is my Component name and BusinessObject as a Class name.can...
5
by: Martin Robins | last post by:
I have never dabbled with ASP.NET until now so be warned! I have created a web application with the single default form: WebForm1.aspx and when I try to display it I get this error. My...
1
by: Veeresh | last post by:
I am getting the following error message. I have logged into the system using my user name into the network. How to find out in which account ASP.Net is running?
2
by: Ross | last post by:
Hi I have an application using asp.net that I am running on my PC. The web form has a text box where you can enter a name for a new Photo category then click on the button. The code is...
0
by: Joergen Bech | last post by:
Fairly new to ASP.NET 1.1. Getting the error below when running application on a web server outside of my control, but only the first time I run it: 1. After a long period of inactivity (or...
2
by: Aprochko | last post by:
Attempting to access outlook from C# .NET ASP app. Have added reference to COM Microsoft Outlook 11 Object Library. Have included using System.Runtime.InteropServices; using System.Web.Mail;...
5
by: Tony Girgenti | last post by:
Hello. I developed and tested a web application using VS.NET 2003, VB, .NET Framework 1.1.4322, ASP.NET 1.1.4322 and IIS5.1. It uses a web form. Development testing works fine on my...
0
by: Mike | last post by:
When I run my asp.net web app, I keep getting the error message 'Access Denied'. I have all of my web apps running as a particular user id and password which is set in the web.config file but when...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.