Quote Originally Posted by PaMarn View Post
I'd like to join in this conversation (a year later).
I am also moving from VB6 to VB.net and find the absence of control arrays frustrating. It's all very well creating the controls at run time, but how do you place them on your form? For example, if I want a number of labels of text boxes, how do I place them where I want them on the form?
You create the control, set its properties as required and then add it to the appropriate parent, e.g.

vb.net Code:
  1. 'Add a Label to the form.
  2. Dim lbl As New Label
  3.  
  4. With lbl
  5.     .Left = 100
  6.     .Top = 10
  7.     .Width = 50
  8.     .Height = 25
  9. End With
  10.  
  11. Me.Controls.Add(lbl)
  12.  
  13. 'Add a TextBox to a Panel.
  14. Dim tb As New TextBox With {.Left = 10, .Top = 10, .Width = 50, .Height = 25}
  15.  
  16. Me.Panel1.Controls.Add(tb)
That's pretty much exactly what happens when you create controls in the designer too. That simply generates code that gets executed when the form is created. If you want to see that code, click the Show All Files button at the top of the Solution Explorer window and then expand the node for the form.