Dim x As Integer
Dim txt As TextBox
Dim lab As Label
Dim startpoint As Integer = 50
x = TextBox1.Text.ToString
For i As Integer = 0 To x
txt = New TextBox
txt.Location = New System.Drawing.Point(12, startpoint)
txt.Name = "TextBox" & i
txt.Size = New System.Drawing.Size(100, 20)
Me.Controls.Add(txt)
lab = New Label
lab.AutoSize = True
lab.Location = New System.Drawing.Point(150, startpoint)
lab.Name = "ti" & x
lab.Size = New System.Drawing.Size(25, 13)
lab.TabIndex = 13
lab.Text = ""
Me.Controls.Add(lab)
startpoint += 25
Next