event order

  • Thread starter Thread starter yoramo
  • Start date Start date
Y

yoramo

Hello

I have a page and on this page I have implemented 2 events
1. Page_Load
2. ButtonClick

I expect that when I press on the button the buttonClick event will be fired
and only afterwords the Page_load.

amazingly the evets order is not that the page_load comes before the button
click event.

is it right ? do i need to implement other events?

Yoramo.
 
yoramo said:
Hello

I have a page and on this page I have implemented 2 events
1. Page_Load
2. ButtonClick

I expect that when I press on the button the buttonClick event will be fired
and only afterwords the Page_load.

amazingly the evets order is not that the page_load comes before the button
click event.

is it right ? do i need to implement other events?

Yes, that is the right order (Page_Load then button click events).

A pretty decent description of the page lifecycle is in this article:


http://msdn.microsoft.com/library/en-us/dnaspp/html/aspnet-pageobjectmodel.asp

The events you need to handle are entirely dependent on your application.
 
Back
Top