The Application and Page Events
You may recall that an "application" in ASP.NET is essentially all of the physical parts that sit in an IIS application, either from the site root or a subfolder marked as an application in its IIS property sheet. This application, running as an instance of HttpApplication, has a number of events that occur throughout the life of a request. These are intermingled with events that happen in the life of the Page object, created every time a request for a page is made. A number of methods also fire in the life of a Page. Some of the more relevant events and methods in the life of a page request are shown in Table 7.1.
HttpApplication | Page | Control |
---|---|---|
BeginRequest | ||
AuthenticateRequest | ||
AuthorizeRequest | ||
ResolveRequestCache | ||
Page Constructor fires | ||
AcquireRequestState | ||
PreRquestHandlerExecute | ||
CreateControlCollection | ||
method | Init | |
trackViewState method | ||
Init | ||
TRackViewState method | ||
LoadViewState method | ||
Load | ||
DataBind | ||
Load | ||
Postback event handler methods | ||
PreRender | ||
SaveViewState method | ||
SaveViewState method | ||
Render method | ||
RenderControl method | ||
Unload | ||
Dispose | ||
Unload | ||
Dispose | ||
ReleaseRequestSate | ||
UpdateRequestCache | ||
EndRequest |