I have a ComboBox hosted in a ListView and I need changes in the CombBox to update the supporing class that the ListView is bound to.
Here is my DataTemplate
<DataTemplate x:Key="Category">
<ComboBox IsSynchronizedWithCurrentItem="False"
Style="{StaticResource DropDown}"
ItemsSource="{Binding Source={StaticResource Categories}}"
SelectedValuePath="Airport"
SelectedValue="{Binding Path=Category}"
/>
</DataTemplate>
This is the Listview. The ItemSource for the ListView is a collection of Airports and is set in code behind, and has a property called Category that I need the combobox to update.
<ListView.View>
<GridView>
<GridViewColumn DisplayMemberBinding="{Binding Path=Name}" Header="Airport" Width="100" />
<GridViewColumn Header="Category" Width="100" CellTemplate="{StaticResource Category}" />
</GridView>
</ListView.View>