|
-
May 30th, 2002, 05:13 PM
#1
Thread Starter
Registered User
Need Control Array For This, Vb.net
I am loading a form which has Eight comboBoxes, named ComboStation1, ComboStation2, ComboStation3, etc. In each combobox I have to add 118 City names. Since Vb.net doesn't support control arrays, and there is no event for add_handler to handle such a task, is this the only way to program that....
VB Code:
Private Sub Combostation1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
comboSTATION1.Items.Add("Akron, OH"))
comboSTATION1.Items.Add("Albany, NY")
End Sub
and do that eight times. 8 * 118 = 944 lines of code to do such a simple task. IF ANYONE knows an easier way, i would greatly appreciate it.
thanks,
Jeff
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|