needed a combobox to display,textbox for input and button.
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
ComboBox1.Items.Add(TextBox1.Text)
End Sub
Jx_Man
Senior Poster
3,526 posts since Nov 2007
Reputation Points: 1,482
Solved Threads: 515
Skill Endorsements: 64
open connection is required to connect.
Jx_Man
Senior Poster
3,526 posts since Nov 2007
Reputation Points: 1,482
Solved Threads: 515
Skill Endorsements: 64
Question Answered as of 5 Years Ago by
Jx_Man hi frnds..
i have same query but i want to use Add Range Method to fill me combo box..
please guide
Ehtesham Siddiq
Junior Poster in Training
59 posts since Aug 2011
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0
A thread is available for this Issue.
Here are both the ways to fill a combobox.
By Add() and Addrange()
By Add()
combobox1.Items.Add("Sunday")
combobox1.Items.Add("Monday")
combobox1.Items.Add("Tuesday")
combobox1.Items.Add("Wednesday")
combobox1.Items.Add("Thursday")
combobox1.Items.Add("Friday")
combobox1.Items.Add("Saturday")
By AddRange()
Dim days() As String = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"}
ComboBox1.Items.AddRange(days)
Ehtesham Siddiq
Junior Poster in Training
59 posts since Aug 2011
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0