Data binding problem

G

Gabriel

Hello,

I'd like to make something easy, in theory.

In C#, I have a database, and some textbox, I'd like to bind theses textbox,
that's that work.

But I'd like update the change (update database) and I push on a button, I
tried the Update of the DataAdapter but that's not work.

Could you help me?

A full sample is welcome.

Thanks,
 
D

Dmytro Lapshyn [MVP]

Hello,

If the focus is in the text box when you click the "Update" button with the
mouse, chances are that the textbox doesn't lose the focus and therefore,
does not notifies the bound data source that the data have been changed. If
this is the case, you should programmatically remove the focus from the text
box before calling DataAdapter.Update();
 
G

Gabriel

If the focus is in the text box when you click the "Update" button with
the
mouse, chances are that the textbox doesn't lose the focus and therefore,
does not notifies the bound data source that the data have been changed.
If this is the case, you should programmatically remove the focus from the
text box before calling DataAdapter.Update();

Hello,

Sorry I tried but that's not work. Do you have a full sample ?

Thanks,
 
D

Dmytro Lapshyn [MVP]

Sorry to hear that. I don't have a sample, but could you please post your
code instead so I can look into it and probably suggest what's wrong?
 

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