动态加载用户控件

asp

2012-04-27 13:22

 (Page.FindControl("form1") as Control).Controls.Add(LoadControl("WebUserControl5.ascx"));

 (Page.FindControl("form1").FindControl("Panel1") as Control).Controls.Add(LoadControl("WebUserControl4.ascx"));