dynamically adding controls to a form
basically my app loads forms from a text file and i want a check box to appear on a form for every form loaded up, im still really new to this so if anyone can help i will really appreciate it ive enclosed my code, the first check box appears on the form fine, its just none of the others do!
thanks
basically my app loads forms from a text file and i want a check box to appear on a form for every form loaded up, im still really new to this so if anyone can help i will really appreciate it ive enclosed my code, the first check box appears on the form fine, its just none of the others do!
VB.NET:
Dim i As Integer
i = 1
While numforms > i
Dim bt As New CheckBox
bt.Text = Val(i)
frmExplore.Controls.Add(bt)
i = i + 1
End While
frmExplore.Show()