473,395 Members | 1,613 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,395 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 6731
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: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.