, ,
(x = 0; x < panel.Controls.Count; ++)
However, if you are dynamically viewing controls in a panel, you might consider providing them with unique names or other identification attributes through the .Name or .Tag properties.
You can then more clearly distinguish your child controls.
Hope this helps ...
source
share