ASP.NET 4 Page Life Cycle

Jan 18, 2010 Posted by Lara Kannan
When an ASP.NET 4.0 page runs, the page goes through a life cycle in which it performs a series of processing steps. These include
  • initialization
  • instantiating controls
  • restoring and maintaining state
  • running event handler code and
  • rendering.
It is important for you to understand the page life cycle so that you can write code at the appropriate life-cycle stage for the effect you intend.

The following diagram shows some of the most important methods of the System.Web.UI.Page class that you can override in order to add code that executes at specific points in the page life cycle.
It also shows how these methods relate to page events and control events. A preliminary version of the diagram was added to the ASP.NET 4 Beta 2 page life cycle documentation on MSDN.



Use the technology. Happy Coding...!

Share
Labels: ,

Post a Comment