G
germ
I am moving a web application from 1.1 to 2.0
This site builds pages dynamically as :
PlaceHolder.Controls.Add(LoadControl("~/Controls/Ctl1.ascx"));
Everything is working fine as long as the web site is updateable - the .ascx
files exist on disk.
I would like to use the non-updateable and single assembly options - no
..ascx files.
I thought that maybe this would work :
PlaceHolder.Controls.Add(LoadControl("AppNameSpace.Controls.Ctl1",null));
This creates the proper object as defined by the code behind class.
However it never creates any child controls - textboxes etc.
Is there an additional step required to instantiate the page controls ?
Is there a class for the .ascx half of the control that I should be loading
instead ?
...
Gerry
This site builds pages dynamically as :
PlaceHolder.Controls.Add(LoadControl("~/Controls/Ctl1.ascx"));
Everything is working fine as long as the web site is updateable - the .ascx
files exist on disk.
I would like to use the non-updateable and single assembly options - no
..ascx files.
I thought that maybe this would work :
PlaceHolder.Controls.Add(LoadControl("AppNameSpace.Controls.Ctl1",null));
This creates the proper object as defined by the code behind class.
However it never creates any child controls - textboxes etc.
Is there an additional step required to instantiate the page controls ?
Is there a class for the .ascx half of the control that I should be loading
instead ?
...
Gerry