Execution order of PageLoad for user controls

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello all

I am trying to understand the execution order of the PageLoad routines in two different user controls on the same page. In particular, I need one to execute before the other, but I can't seem to change the order. It doesn't appear to depend on the order in which they are registered on the page. Any thoughts

Thanks

Bill Borg
 
Hi,

basically you can't rely on order of the events. You make things sure by
calling custom methods (which do the task you now have in event handlers) of
the user controls in order, say in Page's Load event handler.

--
Teemu Keiski
MCP, Microsoft MVP (ASP.NET), AspInsiders member
ASP.NET Forum Moderator, AspAlliance Columnist

Hello all,

I am trying to understand the execution order of the PageLoad routines in
two different user controls on the same page. In particular, I need one to
execute before the other, but I can't seem to change the order. It doesn't
appear to depend on the order in which they are registered on the page. Any
thoughts?

Thanks,

Bill Borg
 
Back
Top