I'll just assume you don't know the difference betwen VB & VC#, which is not a good start. Could you also phrase your problem as a question too, you don't really give any indication anything is wrong; anyhoo:
Your code doesn't seem to show any problems, the only thing you have not showed is how your displaying the table to your form. And I suppose here in lies the problem. Add a Placeholder object to the form and add the table to the Placeholder. Private table As New HtmlTable()
Private cell As HtmlTableCell
Private row As HtmlTableRow
Private tb As TextBox
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
For i As Integer = 0 To 9
tb = New TextBox()
tb.Attributes.Add("runat", "server")
tb.MaxLength = 100
tb.ID = "TextBox" + i.ToString
cell = New HtmlTableCell()
cell.Controls.Add(tb)
row = New HtmlTableRow()
row.Cells.Add(cell)
table.Rows.Add(row)
Next
Placeholder1.Controls.Add(table)
End Sub
Enter your message below
Sign in or Join us (it's free).