I think basically you need some kind of container to put the control into. With a Table, you can use code like the following...
TableRow MyTableRow = new TableRow();
MyTableCell = new TableCell();
MyTextBox = new TextBox();
MyTextBox.ID = "MyTextBox";
MyTableCell.Controls.Add(MyTextBox);
MyTableRow.Cells.Add(MyTableCell);
MyTable.Rows.Add(MyTableRow);
HTH,
Lynn Curtner
> ----------
> From: bimalka[SMTP:bimalkaw@a...]
> Reply To: aspx_beginners
> Sent: Thursday, August 15, 2002 1:40 PM
> To: aspx_beginners
> Subject: [aspx_beginners] web form control during run time
>
>
> Hi
>
> How can I create a web form control(eg a button) during runtime using
> "code behind"
>
> bimalka
> ---
> Beginning ASP.NET 1.0 with C#
> Entirely revised and updated for the final release,
> provides a step-by-step introduction with plenty of
> worked examples to help you to gain a deep understanding
> of what ASP.NET is all about, and how you can harness it
> to build powerful web applications.
> http://www.wrox.com/acon11.asp?ISBN=1861007345
>