3

要了解 ASP.NET 页面生命周期,我认为了解 Page.ProcessRequest 方法更重要,因为 ProcessRequest 方法调用页面的所有事件和方法。有谁知道在代码级别如何在 Page.ProcessRequest 方法中安排事件和方法调用(反射器代码也可以)?

4

1 回答 1

2

我相信您正在寻找从 ProcessRequest 运行的以下方法顺序

The processRequest() method cycles through the page's life cycle in the order listed below.

Methods                 Description
Page_Init                   Page Initialization
LoadViewState           View State Loading
LoadPostData            Postback Data Processing
Page_Load                   Page Loading
RaisePostDataChangedEvent   PostBack Change Notification
RaisePostBackEvent          PostBack Event Handling
Page_PreRender          Page Pre Rendering Phase
SaveViewState           View State Saving
Page_Render                 Page Rendering
Page_Unload Page            Unloading

有关更多信息,请参阅链接http://www.dotnettutorials.com/tutorials/performance/page-life-cycle-asp.aspx

于 2012-08-01T08:25:29.963 回答