I have made two web user controls (Control_1 and Control_2) with some labels and buttons on it.
Is it possible to load Control_2 dynamic at runtime in Control_1?
Control_1 is part of the web page default.aspx.
So in the page_load of Control_1 I thought to use following code:
Control_2 myControl = new Control_2();
myPlaceHolder.Controls.Add(myControl);
But this does not work.
Any ideas?
Thanks.
Is it possible to load Control_2 dynamic at runtime in Control_1?
Control_1 is part of the web page default.aspx.
So in the page_load of Control_1 I thought to use following code:
Control_2 myControl = new Control_2();
myPlaceHolder.Controls.Add(myControl);
But this does not work.
Any ideas?
Thanks.