Here's a basic question:
I'm trying to add rows to a table dynamically.
My current code only creates 1 row w/ 2 cells in it:
This displays "ROW 1ROW2" when I'm looking for:
ROW 1
ROW 2
What am I missing here that's not letting it create 2 rows in output?
Thanks!
I'm trying to add rows to a table dynamically.
My current code only creates 1 row w/ 2 cells in it:
Code:
Dim r As New TableRow()
Dim c As New TableCell()
c.Controls.Add(New LiteralControl("ROW 1"))
r.Cells.Add(c)
tbl.Rows.Add(r)
c.Controls.Add(New LiteralControl("ROW 2"))
r.Cells.Add(c)
tbl.Rows.Add(r)
This displays "ROW 1ROW2" when I'm looking for:
ROW 1
ROW 2
What am I missing here that's not letting it create 2 rows in output?
Thanks!