I would like to add my DataTable return data to my DataGridTemplateColumn.CellEditingTemplate combobox, But the combo box is empty
My xaml code as follow
<DataGridTemplateColumn Header="Student">
<DataGridTemplateColumn.CellEditingTemplate >
<DataTemplate>
<ComboBox ItemsSource="{Binding dtStudent}" DisplayMemberPath="StudentName"/>
</DataTemplate>
</DataGridTemplateColumn.CellEditingTemplate>
</DataGridTemplateColumn>
Back-End
dtStudent = new Function().Sel_Student(); //Function that return student detail
I try to add a Name for the combobox control , but it is not accessible from the back-end .
Is my binding method wrong or do I have other method to achieving what I need