I want to add my user control in InstantiateIn like this:
public void InstantiateIn(Control container)
{
PIMVisualizer pimVisualizer = new PIMVisualizer();
container.Controls.Add(pimVisualizer);
container.Controls.Add(new Button() {Text="asdf"});
}
but the control doeas not appear on the page (the button does). The control is trivial, I am just testing the approach:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="PIMVisualizer.ascx.cs" Inherits="PIMVisualizer" %><asp:Label ID="Label1" runat="server" Text="UC"></asp:Label>
but still, why does not the text "UC" appear onthe page?