Normal 0 21 false false false FR-BE X-NONE X-NONE
Hi,
I’m using v10.3 for Windows.
I added a multi-select UltraComboEditor to a column of my UltraGrid which is bound with a DataSet. I did this using UltraComboEditor.CheckedListSettings properties and UltraGrid.EditorComponent.
Now, imagine my UltraCombo contains 2 items (ID – Text):
If I check both items, the cell displays “Item 1, Item 2”. Fine!
But when I save the DataSet, the saved value is “Item 1, Item 2” and that’s my problem. I want to save the identifiers of my selected items like “1, 2”.
How could I do this?
Is it possible to have a displayed text different from the data value for a cell when using an UltraComboEditor for this cell?
Thank you in advance
Hey,Thank you for your quick response !So, if I want to display the text of my items but save their identifiers, I have to add an unbound column which displays the texts and fill my bound column with the values I want to store. I didn't think to this. Nice workaround :)Thank you.
Hello,
When UltraCombo is in multiselect mode, then it returns its value as an array of objects and if the DataType of the source column in the UltraGrid is different than Object, then the Cell gets the string representation of the value from the UltraCombo. In the attached sample you could see one simple approach of how to avoid this behavior. Please run the sample and select several values from IDUn column, leave the column in order to commit the changes and see how the actual values in column ID gets changed.
I hope this help.