WPF ComboBox

Apr 10, 2009 at 10:52 AM
I have a combobox on the form which displays a list of items for Salutations. i.e Mr., Mrs., etc
The combobox is binded by setting its SelectedValuePath and DisplayMemberPath to the result of the DataTable. However the strange thing is that if you also set the SelectedValue="{Binding}" to the table that is using this information, on loading your data, if you move through the collection, the combobox somehow creates a change in tha DataSet even though nothing has changed. If you check the DataSet.HasChanges it will return true on first load. One has to move form the initial record to another record and call AcceptChanges.
If you then manually call AcceptChanges, then any subsequent navigation through the collection will not create this incorrect behaviour.