Selected item in the combo box

chidambaram

Well-known member
Joined
Dec 27, 2007
Messages
62
Location
Chennai,India
Programming Experience
Beginner
hai,

I created 10 combo boxes in the run time.

How can i get the selected item of that combo boxes?

Urgent plz...

thanks in advance..
 
You need a variable to access any object. If you haven't used an array or collection to store references to those controls then you cannot access them anywhere but in there own event handlers.

If you've used the AddHandler statement to attach a method to an event of those ComboBoxes, e.g. SelectedIndexChanged, then in that event handler the 'sender' argument refers to the ComboBox that raised the event. That means that you can access the SelectedItem of the sender.
 
Back
Top