----------------------------------------------------------- New Message on BDOTNET
----------------------------------------------------------- From: Soumitra2105 Message 3 in Discussion Hi Varad, Which event is out of order ? Best Regards, Soumitra From: Varad_RS [mailto:[EMAIL PROTECTED] Sent: Saturday, August 28, 2004 12:43 PM To: AhmedabadUserGroup; BDotNet; ChennaiNetUserGroup; DotNetSIG; dotnetusergroupHyd; MSDotNetIndore; MumbaiUserGroup; netbloomingtonusergroup Subject: ASP.NET Page Execution : More Detail New Message on MS Dot Net Indore ASP.NET Page Execution : More Detail Reply Reply to Sender Recommend Message 1 in Discussion From: Varad_RS Here I want to explain the basics on what order events and methods get executed during the lifecycle of a request. Its essential to understand this order when debugging what can be complex bugs in Page and WebControl code. Here's a short exercise that will help you internalize what is happening during the creation and execution of a page. Do this without looking up the answer, and it will really make you think through what is happening. Put the following events in order, assuming the request is a PostBack resulting from a Button click: Unload Pre-Render Handle Postback Events Dispose Save State Load View State Load Button Click Handler Process Postback Data Initialize Send Postback Change Notifications Render You can lookup the answer in MSDN http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconcontrolexecutionlifecycle.asp, but realize that at least one of the events is out of order in the documentation. Consider the events in your Global.asax class on the first request received by an application not yet started: Authorize Request Application Start Authenticate Request End Request Page Execution Begin Request Session Start The next time you try to access ViewState during the Init event, you'll know why it doesn't work correctly. Happy .NET Programming! Regards, Varad Microsoft Solutions Group Satyam Computer Services LTD., View other groups in this category. ----------------------------------------------------------- To stop getting this e-mail, or change how often it arrives, go to your E-mail Settings. http://groups.msn.com/BDOTNET/_emailsettings.msnw Need help? If you've forgotten your password, please go to Passport Member Services. http://groups.msn.com/_passportredir.msnw?ppmprop=help For other questions or feedback, go to our Contact Us page. http://groups.msn.com/contact If you do not want to receive future e-mail from this MSN group, or if you received this message by mistake, please click the "Remove" link below. On the pre-addressed e-mail message that opens, simply click "Send". Your e-mail address will be deleted from this group's mailing list. mailto:[EMAIL PROTECTED]
