Home Forums WinForms controls Xceed Grid for WinForms Creating an ComboxEditor Reply To: Creating an ComboxEditor

User (Old forums)
Member
Post count: 23064

Now i use an own control instead of the ComboBoxEditor.

Code:

CFComboBox

comboBox = new CFComboBox();

//comboBox.AutoSize = true;

//comboBox.Dock = DockStyle.Fill;

comboBox.DataSource = valuelist;

comboBox.DisplayMember =

“Description”;

comboBox.ValueMember =

“Value”;

pCellEditorManager =

new CellEditorManager(comboBox, “SelectedValue”, true, true);

pCellViewerManager =

new CellViewerManager(comboBox, “SelectedValue”);

Now the list is visible and filled in, the correct data is also preselected.
But when i change the data, the change doesnt stick, it just returns to the orginal value.

Example

Valuelist:
Value (int)                Description(string)
1                       Car1
2                       Car2
3                       Car3

The preselected value is 2 => in the combobox the text “Car2” is selected. When I change the value through the list from “Car2” to “Car3”, the cell stays on “Car2”

Imported from legacy forums. Posted by Insider (had 803 views)