Multiselect-ComboBox icon indicating copy to clipboard operation
Multiselect-ComboBox copied to clipboard

Extending this to a Datagrid

Open melsawy93 opened this issue 3 years ago • 1 comments

Hi, extremely useful combobox that ive been looking for. I am trying to extend this to work with a datagrid but no luck. I have a really simplified project that implements this on a single combobox and it works. However whenever I try to use this in a datatemplate column, it crashes as soon as I select an item from the drop down. Any hints? Im new to WPF. WPFTestApp MultiComboBox.zip

melsawy93 avatar Oct 26 '22 17:10 melsawy93

So I figured out the issue. The internal selecteditems container is of type observablecollection. I didnt expect this to be hard coded especially if you have SelectionMode="Single". Is there any workaround for this? I am binding the selecteditem of the combobox to a single value not an observablecollection.

melsawy93 avatar Oct 26 '22 20:10 melsawy93

We've added SelectedItem dependency property that internally manages SelectedItems as well, for this purpose (PR #83). Hope it helps.

sdolhaor avatar Dec 16 '22 09:12 sdolhaor