Hi everybody!
Using MVVM style i succefully bound an ObservableCollection to a listbox, showing up the values as radiobuttons. The control behaves exactly as expected.
Now i have an issue regarding some textboxes bound to this listbox: i want whenever the SelectedItem in the listbox is equal to a specific value (e.g. 'ValueForEnabled') the textboxes to be enabled otherwise they should be disabled.
I know i have to bind to SeletedItem of the listbox (named lbSource) but how exactly is this done?
I want something like this (Pseudo code):
<TextBox ...
IsEnabled="{Binding ElementName=lbSource , Path=SelectedItem='ValueForEnabled' , Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
...
/>
Thanks in advance