Could not load file or assembly 'App_Web_xxxx' or one of its dependencies. The system cannot find the file specified.
2009-11-23 08:44
507 查看
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。
在ASP.NET 2.0 开发过程中,有时候开发人员可能会遇到这样的页面异常:
Could not load file or assembly 'App_Web_****, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
异常信息中的****是一个随机字符串,我们知道App_Web_****是一个ASP.NET即时编译的临时程序集。
我是今天在用Orcas beta 1开发一个基于WCF服务的浏览器应用时遇到该问题的,通常地讲,这是一个ASP.NET 2.0处理临时程序集的已知问题,ASP.NET论坛上的billr578说微软建议:
(they suggested) setting batch compilation to false. Basically put batch="false" in the compiliation tag in your web.config. Apparently this is an issue they're working on.
也就是说在web.config里配置成这样子:
<compilation debug="true" batch="false">
相关文章推荐
- Parser Error Message: Could not load file or assembly 'Telerik.Web.UI' or one of its dependencies.解决方法
- Could not load file or assembly 'System.Web.Helpers...错误
- Could not load file or assembly "App_Licenses.dll" " Could not load file or assembly App_Web_"
- Could not load file or assembly 'XXXXXXXX' or one of its dependencies. 试图加载格式不正确的程
- could not load file or assembly 'system.web.mvc version=1.0.0.0'
- Could not load file or assembly 'System.Web.WebPages.Razor, Version=1.0.0.0, Culture=neutral, Public
- 解决Could not load file or assembly 'App_Web_xxxx' or one of its dependencies.
- .net framework 4.0 mvc 应用部署 System.Web.Mvc 错误 Could not load file or assembly 'System.Web.Mvc
- Could not load file or assembly 'App_Web_xxxx' or one of its dependencies. The system cannot find the file specified.
- Could not load file or assembly '*.dll' or one of its dependencies.
- Could not load file or assembly 'log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=692fbea5
- Could not load file or assembly'System.Data.SQLite.dll' or one of its depedencies
- SQLite 解决:Could not load file or assembly 'System.Data.SQLite ... 试图加载格式不正确的程序
- Could not load file or assembly 'XXX' or one of its dependencies
- Could not load file or assembly 'XXX' or one of its dependencies.
- Could not load file or assembly system.data.sqlite.dll or one for it's depedencies
- Could not load file or assembly 'DotNetOpenAuth.OAuth.Consumer'
- Could not load file or assembly 'AjaxControlToolkit, Version=3.0.11119.25533, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e'
- Could not load file or assembly 'ESRI.ArcGIS.SOESupport, Version=10.1.0.0, Culture=neutral, PublicKe
- 网站部署 Could not load file or assembly 'XXX' or one of its dependencies. 拒绝访问。