We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Combobox Cell With DataSource Question

Thread ID:

Created:

Updated:

Platform:

Replies:

29839 Jun 3,2005 08:21 PM UTC Jun 4,2005 02:35 AM UTC WinForms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On June 3, 2005 08:21 PM UTC

I have a GridControl that has a column whose CellType is set to "ComboBox" and to which is bound a Collection of objects. i.e.: .ColStyles(COLINDEX).CellType = "ComboBox" .ColStyles(COLINDEX).DataSource = myCollection .ColStyles(COLINDEX).DisplayMember = "Name" .ColStyles(COLINDEX).ValueMember = "ID" .ColStyles(COLINDEX).ExclusiveChoiceList = True Now, when a user selects an item in a cell''s drop-down list, how can I get the object that the displayed text in the cell represents (i.e. something akin to a SelectedItem property)? Or is that not possible?

Administrator [Syncfusion]
Replied On June 4, 2005 02:35 AM UTC

If you set the .ValueMember = Nothing, then the grid(row,Col).Cellvalue should return the object. You can see a sample for this some of teh comboxes you see in \Syncfusion\Essential Studio\3.2.1.0\Windows\Grid.Windows\Samples\CellTypes\ComboboxCells.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;