The sequence of events when creating an ASP.NET page

I am looking for a good tutorial / article that explains the exact sequence of events that occur when a page is created. I never remember the order. I think this is something like parent controls. The Init event is raised, then the child of the Init is called, in the order in which they are placed on the page. Also, when control events are called, what order do they trigger? For example, if a button event is raised, does this event fire before the DataList_ItemDataBound event is raised, if the DataList.DataBind is in the Page_Load event? So, does anyone want to try to explain or direct me to a good article that explains all this?

thank.

+3
source share
5 answers

This link should cover it: MSDN Page Life Cycle

+4
source

Perhaps you are looking for this: alt text

Leona Andrianarivoni.

+4
source

, .

http://www.aspfree.com/c/a/ASP.NET/ASP.NET-Life-Cycle-and-Best-Practices/

- Button , Page Load , , DataBind Page_Load, .

+2

ASP.NET

, . .

  • PreInit
  • Init
  • Initcomplete
  • PreLoad
  • Load
  • LoadComplete
  • PreRender
  • SaveStateComplete
  • Render

" ASP.NET" .

0

- asp.net. , "", .

PreInit - , . IsPostBack, IsCallback IsCrossPagePostBack. -. PreInit .

Init - , Init, -. . -.

InitComplete - , .

PreLoad - .

- , -.

-. , , .

- .

PreRender. .

PreRenderComplete - PreRender.

- , . .

Error - This event occurs only in the case of an unhandled exception.

0
source

Source: https://habr.com/ru/post/1746246/


All Articles