WPF Listbox remove selection by clicking on blank space

后端 未结 4 658
旧时难觅i
旧时难觅i 2021-01-03 03:49

I have a wpf listbox with a custom item template which contains a rectangle. The each item in the listbox can be selected (only one at a time). I w

4条回答
  •  北海茫月
    2021-01-03 04:09

    For The each item in the listbox can be selected (only one at a time).

    You can come up with one of followings

    1- Disable the item after it is selected.

    2- Maintain a list at backend to mark each index selectable or unselectable.

提交回复
热议问题