我以编程方式更新项目。我有一个返回HtmlGenericControl的方法。我想以编程方式将此HtmlGenericControl放入项目的子布局中。 这可能吗?
答案 0 :(得分:0)
我认为你的意思是:
// This is where your method returns the control.
HtmlGenericControl htmlControl = GetControl();
// This is how you add it as a child control of a placeholder
myPlaceHolder.Controls.Add(htmlControl);