O
Ole Hanson
Hi
I am having a number of User Controls (ascx) on my page (aspx).
The page is in my scenario only working as a dumb "container "giving life to
the Controls, as these are handling my UI-logic and communicating with each
other (the controls are communicating) by subscribing to each others events.
(e.g. pressing a selection in Control1 will "trigger" the content of
Control2).
It is done in this way:
I wire up Control2 to subscribe to events from Control1. This is done in the
Page_Load event of Control2, by first letting Controls2 obtain access to
it's parent (this.Page.Controls) and then locating Control1's events to
subscribe to. It is a quite brilliant framework letting the UI-controls
communicate via the page.
Question: How to I make sure the controls are loaded by the hosting Page,
before doing the eventwiring (Subscribe)??
/Ole
I am having a number of User Controls (ascx) on my page (aspx).
The page is in my scenario only working as a dumb "container "giving life to
the Controls, as these are handling my UI-logic and communicating with each
other (the controls are communicating) by subscribing to each others events.
(e.g. pressing a selection in Control1 will "trigger" the content of
Control2).
It is done in this way:
I wire up Control2 to subscribe to events from Control1. This is done in the
Page_Load event of Control2, by first letting Controls2 obtain access to
it's parent (this.Page.Controls) and then locating Control1's events to
subscribe to. It is a quite brilliant framework letting the UI-controls
communicate via the page.
Question: How to I make sure the controls are loaded by the hosting Page,
before doing the eventwiring (Subscribe)??
/Ole