I am trying to get a combobox to work inside a grid. the combobox uses a collection as it's datasource. I have the combobox displaying the drop down data, but it currently does not store the selected value. here is the xaml snippet
in the collection of GenderTypes ("MyGenderTypes"), Description is the property being displayed in the combobox.
the entity property that will be assigned the selected combobox value is named "GenderType".
what is need to understand is how to bind the selected value of the combobox to the entity property "GenderType" (in XAML).
Also, how would I reference the comboBox in the code-behind file? When defining it inside the data template, it doesn't show up as a referenceable item in intellisence.
Thanks alot,
Jeff
<DataTemplate x:Name="GenderTypeDataTemplate" > |
<telerikInput:RadComboBox x:Name="theGenderTypeLookup" |
ItemsSource="{Binding Source={StaticResource MyGenderTypes}}" |
DisplayMemberPath="Description" |
SelectedValuePath="GenderType" |
Height="20" Grid.Column="2" MinWidth="40" /> |
</DataTemplate> |
in the collection of GenderTypes ("MyGenderTypes"), Description is the property being displayed in the combobox.
the entity property that will be assigned the selected combobox value is named "GenderType".
what is need to understand is how to bind the selected value of the combobox to the entity property "GenderType" (in XAML).
Also, how would I reference the comboBox in the code-behind file? When defining it inside the data template, it doesn't show up as a referenceable item in intellisence.
Thanks alot,
Jeff