J
Johnny E Jensen
Hello
I'm trying to implement a WebUserControl ( MyCtrl.ascx ) to a WebForm (
MyWebForm.aspx )
The MyCtrl.ascx has some properties ( Public String FormTitle ) - and some
others.
In VS.2003 I load the WebUserControl like this:
MyCtrl _Ctrl = (MyCtrl)Page.LoadControl("MyCtrl.ascx");
.... ControlContainer.Controls.Add( _Ctrl );
_Ctrl.FormTitle = "Test";
This way to implements the WebUserControl don't work in Whidbey(VS2005) -
Why?
I'm able to load the WebUserControl to the page with:
Control _ctrl = Page.LoadControl("MyCtrl.ascx");
.... ControlContainer.Controls.Add( _ctrl );
But are not able to access the property FormTitle like _ctrl.FormTitle?
Solutions - any one?
Kind regards
Johnny E Jensen
I'm trying to implement a WebUserControl ( MyCtrl.ascx ) to a WebForm (
MyWebForm.aspx )
The MyCtrl.ascx has some properties ( Public String FormTitle ) - and some
others.
In VS.2003 I load the WebUserControl like this:
MyCtrl _Ctrl = (MyCtrl)Page.LoadControl("MyCtrl.ascx");
.... ControlContainer.Controls.Add( _Ctrl );
_Ctrl.FormTitle = "Test";
This way to implements the WebUserControl don't work in Whidbey(VS2005) -
Why?
I'm able to load the WebUserControl to the page with:
Control _ctrl = Page.LoadControl("MyCtrl.ascx");
.... ControlContainer.Controls.Add( _ctrl );
But are not able to access the property FormTitle like _ctrl.FormTitle?
Solutions - any one?
Kind regards
Johnny E Jensen