Hi,
I have a requirement where in a certain column user should be able to select some values from a list. My approach is to have a column that has a dropdownlist style. When popup I want a checkedlistbox to be displayed where user can select some of many items of type KeyValuePair(string, string).
In the cell itself I wand the list of selected keys to be stored, but in the front end i want the list of Values to be displayed.
Can this be done using UltraWinGrid?
Do you have a quickstart how I could achieve this?
Kind regards
Patrick
Hi Patrick,
Which part of this is giving you trouble?
I think you will need to use either UltraCombo or UltraComboEditor for this and set it up for mutli-select and then attach it to the column in the grid via the EditorComponent property.
Translating from DataValue to DisplayText is simply a matter of setting the correct ValueMember and DisplayMember (if you are binding) or the DataValue and DisplayText on each item (if you are not binding).
Hi Mike,
thanks for your reply. The approach using UltraComboEditor as EditorComponent of the cell is ok. Sorry I did not see the CheckedListSettings on my own. I needed your hint to look again an find it.
My requirement is not fully reached. I use the UltraComboEditor to display my list correctly, using ValueMember and Displaymember. The list is inherited of List<KeyValuePair<string,string>>.
After CloseUp or leaving the cell I can see the selected items value in my gridcell. This could be enough but I would prefer to see the keys instead of values. Is this possible.
Best solution was if I could have the list of values to be displayed in the grid and the list of keys to be synchronized to my underlaying business object.
Any ideas?
Kind RegardsPatrick