我有建立在asp.net MVC3上的應用程序。應用程序運行良好,但我看到一個問題在這裏,每個頁面加載Application_Error方法得到執行多次,同時沒有引發異常,因爲這樣的應用程序永遠不會中斷。 在調試時,我可以看到錯誤消息,但我無法弄清楚爲什麼會出現這個錯誤。我將不勝感激任何幫助。Application_Error被多次調用
[7/24/2011 10:30:04 PM] Error: System.Web.HttpException (0x80004005): File does not exist. at System.Web.StaticFileHandler.GetFileInfo(String virtualPathWithPathInfo, String physicalPath, HttpResponse response) at System.Web.StaticFileHandler.ProcessRequestInternal(HttpContext context, String overrideVirtualPath) at System.Web.DefaultHttpHandler.BeginProcessRequest(HttpContext context, AsyncCallback callback, Object state) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
當我們遇到這個問題時,我的機器上缺少必需的DLL(這是來自Microsoft企業實踐的東西)。嘗試使用ProcMon來歸檔找不到哪個文件。 –