Reputation: 70287
The below code works for a DataGridComboBoxColumn, but ComboBox doesn't have a SelectedValueBinding property. What should I use instead?
<ComboBox
Header="Application"
SelectedValueBinding="{Binding ApplicationKey}"
SelectedValuePath="ApplicationKey"
DisplayMemberPath="ApplicationName"
ItemsSource="{Binding Source={x:Static app:ApplicationLookup.GetAllOrNone}}"/>
Upvotes: 0
Views: 115
Reputation: 2923
Use
SelectedValue = {Binding Property}
or SelectedItem = {Binding Property}
these will have the same effect
and to get the Path that you want to display use
DisplayMemberPath = Property
Upvotes: 1