This is my control at the moment:
<TreeViewItem Header="{Binding ParentName}"> <TreeViewItem Header="{Binding ChildName}" /> </TreeViewItem>
It is supposed to be in a ListBox , but the catch is that I need to be able to select only the parent or child.
This is a simple concept, but I tried so much (wrapping in ListBoxItem. Using extenders and changing visibility manually), but nothing worked. ListBox treats instances of this control as one when it is actually two. Any ideas?
source share