Is there an opposite of BindingSource.ResetBindings?

  • Thread starter Thread starter BC
  • Start date Start date
B

BC

I have a DataGridView bound to a BindingSource which in turn is bound to a
datatable. What I need is essentially the exact opposite of the
BindingSource.ResetBindings.

I need to programmatically force an update of the underlying table when the
value of a cell in a DataGridView changes. Does such a capability exist?
 
I have a DataGridView bound to a BindingSource which in turn is bound to a
datatable. What I need is essentially the exact opposite of the
BindingSource.ResetBindings.

I need to programmatically force an update of the underlying table when the
value of a cell in a DataGridView changes. Does such a capability exist?

Have you tried BindingSource.EndEdit()?
 
That's it! An EndEdit call in the CellLeave event handler. Works perfectly.
I was so focused on the grid, I didn't spend enough time looking at the
BindingSource.

Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top