“/”应用程序中的服务器错误。

对路径“D:\wwwroot\www.xnkc99.com\web\Config\Global.config”的访问被拒绝。

说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.UnauthorizedAccessException: 对路径“D:\wwwroot\www.xnkc99.com\web\Config\Global.config”的访问被拒绝。

ASP.NET 未被授权访问所请求的资源。请考虑授予 ASP.NET 请求标识访问此资源的权限。ASP.NET 有一个在应用程序没有模拟时使用的基进程标识(通常,在 IIS 5 上为 {MACHINE}\ASPNET,在 IIS 6 上为网络服务)。如果应用程序正在通过 <identity impersonate="true"/> 模拟,则标识将为匿名用户(通常为 IUSR_MACHINENAME)或经过身份验证的请求用户。

To grant ASP.NET access to a file, right-click the file in File 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.

源错误:


行 18: <ul class="bt_rt">
行 19:     <li><input type="text" value="24小时电话咨询热线400-6982-400" class="ipt1" onclick="tqq()"/></li>
行 20:     <li class="bt"><a <%= NSW.OConfig2.SMTP.SiteServiceURL %> title="在线咨询"><img style="border: medium none;cursor: pointer;margin: 0 13px 0 28px;" src="/Skins/Default/Img/Index/zx1.gif" alt="在线咨询"/></a><a target="_blank"  href="<%=ColumnNameURl%>" title="了解详情"><img style="border: medium none;cursor: pointer;margin: 0 23px 0 28px;" src="/Skins/Default/Img/Index/zx2.gif" alt="了解详情"/></a></li>
行 21: </ul>
行 22: </div>

源文件: d:\WWWROOT\www.xnkc99.com\web\UserControls\TemplateResource\TemplateProductList02.ascx    行: 20

堆栈跟踪:


[UnauthorizedAccessException: 对路径“D:\wwwroot\www.xnkc99.com\web\Config\Global.config”的访问被拒绝。]
   System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +7741863
   System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy) +1162
   System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share) +66
   System.Xml.XmlTextWriter..ctor(String filename, Encoding encoding) +37
   System.Xml.XmlDocument.Save(String filename) +77
   NSW.Utls.XmlUtls.Set(String key, String newValue, String path) +289
   NSW.OConfig.GlobalConfig.Save(String key, Object val) +120
   NSW.OConfig.GlobalConfig.set_ServiceQQ1(String value) +36
   NSW.OConfig2.SMTP.get_SiteServiceURL() +796
   ASP.usercontrols_templateresource_templateproductlist02_ascx.__Render__control2(HtmlTextWriter __w, Control parameterContainer) in d:\WWWROOT\www.xnkc99.com\web\UserControls\TemplateResource\TemplateProductList02.ascx:20
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +256
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
   System.Web.UI.Control.Render(HtmlTextWriter writer) +10
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +134
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
   System.Web.UI.Control.Render(HtmlTextWriter writer) +10
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +134
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
   System.Web.UI.Control.Render(HtmlTextWriter writer) +10
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
   ASP.index_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in d:\WWWROOT\www.xnkc99.com\web\index.aspx:50
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +256
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
   System.Web.UI.Page.Render(HtmlTextWriter writer) +29
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1266


版本信息: Microsoft .NET Framework 版本:2.0.50727.8813; ASP.NET 版本:2.0.50727.8951