PC Review Forums Newsgroups Microsoft DotNet Microsoft Dot NET Framework Forms Re: Data bound updates not updating

Reply

Re: Data bound updates not updating

 
Thread Tools Rate Thread
Old 24-06-2003, 07:23 PM   #1
Curt Tabor
Guest
 
Posts: n/a
Default Re: Data bound updates not updating


Can anyone at least tell me if this is how they do it? TIA.

Curt

"Curt Tabor" <curt_tabor@cox.net> wrote in message
news:QwGJa.43921$1e.3571@fed1read04...
> Hello, I'm using the following code to change some data using OleDb data
> adapters. Basically, I've got a form with a grid of data and I'm showing a
> dialog and updating the changes if the user presses OK. This seems really
> straight forward but there are a couple of problems.
>
> The data does not get updated to the database unless I make a second

change.
> Each time I edit the data in the dialog, only the previous chage will get
> posted to the database. Sometimes it will not get posted at all. Also, the
> grid on the calling form will not reflect the changes made to the data

until
> it gets focus. I must be doing something wrong. I just can't figure out

what
> it is.
>
> Thanks in advance for any feedback.
>
> public void Editxxx()
> {
> TDlgEditxxx DlgEditxxx = new TDlgEditxxx();
>
> DlgEditxxx.tbxxxName.DataBindings.Add("Text", DataCtrl.dsMain,
> "SOMEQUEREY.NAME");
>
> DlgEditxxx.ShowDialog();
>
> if (DlgEditxxx.DialogResult == DialogResult.OK)
> DataCtrl.aDataAdapter.Update(DataCtrl.dsMain);
>
> DlgEditxxx.Dispose();
> }
>
>
> --
> Curt Tabor
> Lead Software Engineer
> SmartDialolgue Inc.
>
>



  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off