Could not load file or assembly 'App_Web_xxxx' or one of its dependencies. The system cannot find the file specified.

Stack Trace:
[FileNotFoundException: Could not load file or assembly 'App_Web_csf6r1ov, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.]
   ASP.usercontrol_defaultpage_righttopsearch_ascx.__BuildControlTree(usercontrol_defaultpage_righttopsearch_ascx __ctrl) +0
   System.Web.UI.UserControl.InitializeAsUserControl(Page page) +53
   ASP.default_aspx.__BuildControlRighttopsearch1() +73
   ASP.default_aspx.__BuildControlTree(default_aspx __ctrl) +1079
   ASP.default_aspx.FrameworkInitialize() +51
   System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +55
   System.Web.UI.Page.ProcessRequest() +105
   System.Web.UI.Page.ProcessRequest(HttpContext context) +292
   ASP.default_aspx.ProcessRequest(HttpContext context) +16
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +499
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +177

出现场景:页面可以正常访问没有更新任何地方,突然就出现了这个错误。
解决方案:解决的方法很奇怪,将发生错误的页面上加上debug="true"的指令,然后访问出错的页面,这时候页面就可以正常访问了;然后再把debug="true"去掉也可以正常访问。
这应该是microsoft的一个bug。

 

原文地址:https://www.cnblogs.com/yukaizhao/p/microsoft_bug_net20_1.html