BindingManagerBase.EndCurrentEdit doesn't end the current edit

G

Guest

I have a data entry form with a grid. When the user changes data in a
column, and then clicks the Red X of the form to close it, I trap this in the
Closing event. I first call the BMB.EndCurrrentEdit, and then call code to
save the data.

The issue is that the data of the current cell in the grid is lost dispite
all of the above. If the user takes any other action first before closing
the form, then all is OK. But if he goes right to the close button, it is
lost lost lost.

Is there something I am missing here that will flush the data down?
 
P

Pete Davis

Try calling grid.EndEdit(). This should commit any changes to the
CurrencyManager.

Pete
 

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

Top