Should be rather For Each control In Table1.Controls. Note, that Controls
property gives your only child controls for the control. To get the full
list of controls use recursion.
Eliyahu
"anonymou" <> wrote in message
news:1c28301c4521a$8030ddd0$...
> I am trying to loop in table to set all controls visible.
> What is incorrect in my code?
> Dim control As System.Web.UI.WebControls.WebControl
> Dim Table1 As System.Web.UI.WebControls.Table
> For Each control In Table1
> control.Visible = True
> Next
|