473,386 Members | 1,715 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.

how to rectify this access denied problem

271 100+
hi,
when i tried to open a new excel spread sheet from my web form i got this access denied page. can any one help me in solving this problem.
Expand|Select|Wrap|Line Numbers
  1.  
  2. Server Error in '/sk/ContractInvoice' Application. 
  3.  
  4. Access is denied. 
  5.  
  6. [font=Arial, Helvetica, Geneva, SunSans-Regular, sans-serif]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. 
  7.  
  8. Exception Details: System.UnauthorizedAccessException: Access is denied. 
  9.  
  10. 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. 
  11.  
  12. 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.
  13.  
  14. Source Error: 
  15.  
  16. Line 69:         private void DataGrid1_DeleteCommand(object source, System.Web.UI.WebControls.DataGridCommandEventArgs e)Line 70:         {[color=red]Line 71:             Excel.Application ExApp = new Excel.ApplicationClass();[/color]Line 72:             ExApp.Visible = true;Line 73:             Excel.Workbook ExWbk = ExApp.Workbooks.Add(XlWBATemplate.xlWBATWorksheet);
  17. [font=Verdana]Source File: [/font]f:\sk\contractinvoice\contractinvoicereport.aspx.cs[font=Verdana]    Line: [/font]71 
  18.  
  19. [font=Verdana]Stack Trace:[/font] 
  20.  
  21. [UnauthorizedAccessException: Access is denied.]   ContractInvoice.WebForm1.DataGrid1_DeleteCommand(Object source, DataGridCommandEventArgs e) in f:\sk\contractinvoice\contractinvoicereport.aspx.cs:71   System.Web.UI.WebControls.DataGrid.OnDeleteCommand(DataGridCommandEventArgs e) +110   System.Web.UI.WebControls.DataGrid.OnBubbleEvent(Object source, EventArgs e) +589   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +26   System.Web.UI.WebControls.DataGridItem.OnBubbleEvent(Object source, EventArgs e) +106   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +26   System.Web.UI.WebControls.LinkButton.OnCommand(CommandEventArgs e) +121   System.Web.UI.WebControls.LinkButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +115   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +138   System.Web.UI.Page.ProcessRequestMain() +1277
  22.  
  23. [font=Verdana]Version Information:[/font] Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573 [/font]
  24.  

thanks
Feb 15 '07 #1
1 2108
kenobewan
4,871 Expert 4TB
May be permissions on the folder...
Feb 17 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Steve | last post by:
Hi, Yesterday I signed up for another dedicated linux server with the hosting company I use and I am having problems getting MySQL 4.1.3 working on it. I've tried just about everything I can...
9
by: | last post by:
Hi All, I have allready tried to ask a similar question , but got no answer until now. In the meantime, I found, that I cannot understand some thread-settings for the Main() function . If I use...
5
by: Raterus | last post by:
I'm just throwing this error out for my sanity, I've seen posts about this, but never solutions. I'm using VS.NET 2003, Framework 1.1, and I'm getting a random error about every 1 out of 10 times...
16
by: Brad | last post by:
After compiling my asp.net project I'm receiving a "BC31011 - Access is denied" error when attempting to run or debug. The only thing that seems to resolve problem is IISReset. After a reset my...
12
by: Ron Weldy | last post by:
I have a test server runinng 2003/IIS 6 with a mixture of asp and asp.net files. On my workstation I have a share set up to the folder where the web files reside. I am just doing quick and dirty...
3
by: Shailesh Humbad | last post by:
I figured out what was causing the "Access is Denied" error when calling functions from referenced DLLs in my service. I've tried to be very detailed, so bear with me. It turns out that...
3
by: David Thielen | last post by:
Hi; I created a virtual directory in IIS 6.0 and my asp.net app runs fine. But when it tries to write a file I get: Access to the path is denied. - C:\Inetpub\wwwroot\RunReportASP\images ...
8
by: Jeremy Ames | last post by:
I am trying to move an application from my system to a new test system. I really should have tried an easier program first, but I didn't really have a chance. My application was originally written in...
0
by: Andy | last post by:
Thanks Peter, I thought I'd give an update on this problem. My application had 2 assemblies that contained classed for the Data access and business logic layer. It was on one of them that I was...
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: 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
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
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
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.