J
Jeremy
I have been trying to iterate through the controls on my form and preset all
textboxes to a cssClass. Unfortunately, I have been unable to figure out
how to recursively move through sub-controls and all of my textboxes are in
asp panels. The code I have can see the panels but not what is in them.
Help please.
Current code:
Dim frm As Control
Dim ctrl As Control
frm = FindControl("Form2")
For Each ctrl In frm.Controls
If TypeOf ctrl Is TextBox Then
CType(ctrl, TextBox).CssClass = cssTextbox
End If
Next
textboxes to a cssClass. Unfortunately, I have been unable to figure out
how to recursively move through sub-controls and all of my textboxes are in
asp panels. The code I have can see the panels but not what is in them.
Help please.
Current code:
Dim frm As Control
Dim ctrl As Control
frm = FindControl("Form2")
For Each ctrl In frm.Controls
If TypeOf ctrl Is TextBox Then
CType(ctrl, TextBox).CssClass = cssTextbox
End If
Next