I have a nested ListBoxes like a warningListBox item that can contain a picturesListBox and a audioRecordListBox. When I select one element of a child ListBox (es. item of pictureListBox), I need not only to recover the selected picture item but also the item of the parent warning ListBox (item of the warningListBox). In the multimediaListBox_SelectionChanged(object sender, SelectionChangedEventArgs e) I can recover the child item selected
((System.Windows.Controls.ListBox)sender).SelectedItem
but HOW CAN I RECOVER THE ITEM of the PARENT warningListBox??
Must I add in each ListBox child element an additional field with the id of the parent item?? ... or there is a better solution, for example navigating in the sender or using the eventArgs of the SelectionChanged event?
Waiting for some suggestions ...
Enzo Contini