asp.net - what are all the page level events that get fired when a button is clicked? -


This was an interview question

Page level events were removed when a button was clicked. In Asp.net

Will all page level events be removed?

No! Not all events are found after clicking on the button (postback). Page_int Event will not be left on postback. You can study more at this link:

1 - The page for each control on the web form The first stage of the life cycle is the initial phase of the life cycle. In the instx source, all the static declaration is populated with static control. First of all, an init event occurs for the page object, then init events for every control on the page is not available at this level, vestaste information is not available.

2 - Page.LoadViewState After initialization, the ASP.NET loads the scene position for the page. The viewstate contains the status of the situation, which was processed on the server for the last time.

3 - Page.ProcessPostData The post data is read from the request and the control values ​​apply. Marital control in step 1.

4 - Page. Load + Control Load for each control on the page If it is for the first time, the page is being processed (page. ISO postback

5 - Results for "change" event controls The current values ​​(from post data) are compared to the original value in the viewstate, if there are differences, "modified" events are taken.

6 - Kiss server-side event Also, validation is removed for control

7 - Click the button. + Click on the Command button and the command events have been removed due to which the postback

8 - Page. Prerender + control .prerer

9 - Page.SaveViewState to see new values ​​for all controls state

10 - Page .Renders

Reference:

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -