From the course: ASP.NET Web Forms Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Lifecycle

Lifecycle - ASP.NET Tutorial

From the course: ASP.NET Web Forms Essential Training

Start my 1-month free trial

Lifecycle

- So one thing I want to talk about with you right now is about ASP.NET Page Lifecycle, and what that means, it means what is happening while we are running a page, when a page gets loaded by ASP.NET Framework. So let's have a look at it. We have three distinctive phases. The first one is called the init phase. And in that we are actually going to initialize the page. Then we have the load phase, and then last but not least we have the render phase. Now let's talk about each and every one of them, and what exactly happens behind the curtains. So when we start with the PreInit, what we are actually going to do is we are going to prepare the page, meaning that every single control is going to get created, and then once this is done the PreInit event is going to happen. So in our case if we have a method called "page_preinit" that would get called. The next event that would happen would be Init, and in that one we are going to initialize and maybe add some start data inside our controls.…

Contents