Hi,
I am developing a desktop windows application. There is one form which contains a lot of different controls (textbox, label, checkbox, combobox, etc.). I have assigned specific control information to "tag" property for some of these controls, that includes all the textboxes. Later i wrote some codes trying to output these control information to a text file for reference:
For Each i As Control In Me.Controls
If TypeOf i Is TextBox Then
sw.WriteLine(i.Name & " : " & i.Tag.ToString)
End If
Next
(code shows only textbox case)
strangely, no textbox control has been detected through the code above, and the intellesense over the "Me.Controls" tells me that there are only 20 controls for this form, while i know there are a lot more controls than this.
How can i get it right
Thanks.

control type not detected.
Jörg Riedmiller
That really is strange.... do you have them in group boxes or other containers If you do they will not show up in the forms controls collection.
If they are in different kinds of containers you'll have to iterate on the container's control collection.
SnaidiS