Execution order of PageLoad for user controls

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
 
T

Teemu Keiski

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
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,733
Messages
2,569,440
Members
44,830
Latest member
ZADIva7383

Latest Threads

Top