上次得一仁兄康概下载了UDS,试玩了几把出现下面错误,不知何解?Server Error in '/' Application.
--------------------------------------------------------------------------------Access to the path 'c:\udslog.txt' 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 to the path 'c:\udslog.txt' 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. To grant ASP.NET 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.Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace:
[UnauthorizedAccessException: Access to the path 'c:\udslog.txt' is denied.]
System.IO.__Error.WinIOError(Int32 errorCode, String str) +1480039
System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy) +935
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) +112
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options) +52
System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize) +107
System.IO.StreamWriter..ctor(String path, Boolean append) +123
System.IO.File.AppendText(String path) +35
UDS.Components.Error.Log(String message) in D:\项目\UDS\程序源文件\UDS\Components\Error.cs:22
UDS.Components.MailClass.GetMails(Int32 FolderType, String Username) in D:\项目\UDS\程序源文件\UDS\Components\Mail.cs:86
UDS.SubModule.UnitiveDocument.Mail.MailList.BindGrid() in D:\项目\UDS\程序源文件\UDS\SubModule\UnitiveDocument\Mail\Index.aspx.cs:154
UDS.SubModule.UnitiveDocument.Mail.MailList.Page_Load(Object sender, EventArgs e) in D:\项目\UDS\程序源文件\UDS\SubModule\UnitiveDocument\Mail\Index.aspx.cs:63
System.Web.UI.Control.OnLoad(EventArgs e) +102
System.Web.UI.Control.LoadRecursive() +45
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +952
--------------------------------------------------------------------------------Access to the path 'c:\udslog.txt' 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 to the path 'c:\udslog.txt' 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. To grant ASP.NET 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.Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace:
[UnauthorizedAccessException: Access to the path 'c:\udslog.txt' is denied.]
System.IO.__Error.WinIOError(Int32 errorCode, String str) +1480039
System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy) +935
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) +112
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options) +52
System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize) +107
System.IO.StreamWriter..ctor(String path, Boolean append) +123
System.IO.File.AppendText(String path) +35
UDS.Components.Error.Log(String message) in D:\项目\UDS\程序源文件\UDS\Components\Error.cs:22
UDS.Components.MailClass.GetMails(Int32 FolderType, String Username) in D:\项目\UDS\程序源文件\UDS\Components\Mail.cs:86
UDS.SubModule.UnitiveDocument.Mail.MailList.BindGrid() in D:\项目\UDS\程序源文件\UDS\SubModule\UnitiveDocument\Mail\Index.aspx.cs:154
UDS.SubModule.UnitiveDocument.Mail.MailList.Page_Load(Object sender, EventArgs e) in D:\项目\UDS\程序源文件\UDS\SubModule\UnitiveDocument\Mail\Index.aspx.cs:63
System.Web.UI.Control.OnLoad(EventArgs e) +102
System.Web.UI.Control.LoadRecursive() +45
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +952
解决方案 »
- jquery 和 js 都没有让我的图片发生改变,请教
- asp.net中有没有一个控件既可以显示图片又可以显示文字的服务器的超链接控件?
- 我们单位新做的网站,大家给点意见ing...
- datalist编辑怪问题
- dropdownlist 选项对齐的问题
- asp.net(C#)aspx页面调用swf,但swf无法读取其xml文件
- asp.net 新闻系统生成静态页 请有经验的朋友帮帮忙
- 超简单的代码,居然提示SQL Server 不存在或访问被拒绝。
- 求最简单的方法将Enum作为数据源绑定
- 如何做一个asp.net web application
- datagrid中怎样将列显示为固定长度,如果取出数据大于列的长度则显示‘。。。。‘
- 如何写一个链接??????
1、在IIS里配置好访问帐号(有权限)
2、在uds的web.config里加入,加入验证模拟
<identity impersonate="true" />
注意:加入在 <system.web></system.web>里