something like
Private Sub DoIt(ByVal frm as Form)
Dim list As New ArrayList
list.Add(frm.GetType.Name & " -> " & frm.Name & ": " & frm.Text)
AddRecursiveControls(frm.Controls, list)
Debug.WriteLine("--------------------")
For Each s As String In list
Debug.WriteLine(s)
Next s
Debug.WriteLine("--------------------")
End Sub
Private Sub AddRecursiveControls(ByVal cc As Control.ControlCollection,
ByVal list As ArrayList)
Dim ctr As Control
For Each ctr In cc
list.Add(ctr.GetType.Name & " -> " & ctr.Name & ": " & ctr.Text)
AddRecursiveControls(ctr.Controls, list)
Next ctr
End Sub
dominique