Within Each stage of the life cycle the page raises Events that you can handle to run your own code. These are as follows
Raised before the Initialization stage begins Here the Ispostback property is checked to determine whether the first time the page is being processed.
Raised after all the controls have been initialized.
Raised at the end of the page initialization stage.
Raised after the page loads view state for itself and all its controls.
Here the page calls the OnLoad method,Use this method to set the properties in controls and to establish the database connection.
Raised at the end of the event handling stage.
The page object raises the prerender event to make the final changes to the contents of the the page or its controls before the rendering stage begins.
Raised after each data bound control whose DataSourceID property is set calls its DataBind method.
9-Save State Complete
Raised after viewstate and controlstate have been saved for the page and for all the controls.
All the ASP.Net webserver controls have a Render method that writes out the controls markup to the browser.
Raised for each control and then for the page.This event is used to do the final cleanup work, like closing the open files and database connections.