views:

209

answers:

1

I have databound a DataTable to a combobox, and I have a textbox that is also linked to a field in this same table. The Date field updates as expected when switched between records, but changing the value of the Date field causes the list entry in the combobox to change to System.Data.DataRowView. The record still selects fine.

Here is the sample code;

comboBox1.DataSource = TblA;
comboBox1.DisplayMember = "ID";

BindingContext binding = this.BindingContext;

BindingManagerBase IDSelected = binding[comboBox1.DataSource];

textBox1.DataBindings.Add("Text",TblA,"Date");
A: 

Try using Datasource Update Mode to Never

Binding Constructor (String, Object, String, Boolean, DataSourceUpdateMode)

Anuraj