本文介绍了在什么情况下Application_EndRequest叫,但的Application_BeginRequest不叫?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

的HttpApplication的方法所期待的顺序是:

The expected order of HttpApplication methods is:

  1. 的Application_Start
  2. 在初始化
  3. 的Application_BeginRequest
  4. Application_AuthenticateRequest
  5. (页面生命周期)
  6. Application_EndRequest

我路过一个局面,这引发绝对不例外,其中,在初始化后,它会直接ApplicationEndRequest。它不叫的Application_BeginRequest没有启动页面生命cyle。

I'm passing through a situation, which throws absolutely no exception, in which, after the Init, it goes directly to ApplicationEndRequest. It doesn't call Application_BeginRequest neither initiates the page life cyle.

我该怎么办?

推荐答案

Application_EndRequest 的调用,但没有的Application_BeginRequest 时,前的Application_BeginRequest 那里有未处理的异常。

Application_EndRequest is called but not Application_BeginRequest when theres an unhandled exception prior to Application_BeginRequest.

这可能是的Application_Start ,一些模块或初始化 Application_Init

That may be on Application_Start, the initialization of some module or at Application_Init

这篇关于在什么情况下Application_EndRequest叫,但的Application_BeginRequest不叫?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-11 13:11