Subject | RE: [IBO] Cannot post current row |
---|---|
Author | Christian Gütter |
Post date | 2000-12-05T19:33:33Z |
Hi, I've left the two prior postings of this thread
in this message because the last posting is some days
ago.
You (especially Helen) can find my answer at the end
of this mail.
is in dssBrowse State. But why?
I _am editing_ the dataset - I _am modifying_ the value of an TIB_Edit
connected to the dataset and the TIB_UpdateBar connected to the dataset
shows the post-icon in green so that I can post with one little click.
But if I press my hotkey which tries to post the dataset, the "cannot post
current row" error occurs because the dataset is in browse mode.
Maybe I am understanding it wrongly, but if I am editing a value, shouldn't
the dataset be in the dssEdit mode?
Christian
in this message because the last posting is some days
ago.
You (especially Helen) can find my answer at the end
of this mail.
> -----Original Message-----Yes, I've done this, and NeedToPost returns false because the dataset
> From: Helen Borrie [mailto:helebor@...]
> Sent: Thursday, November 30, 2000 10:48 AM
> To: IBObjects@egroups.com
> Subject: Re: [IBO] Cannot post current row
>
>
> At 10:41 AM 30-11-00 +0100, you wrote:
> >Hi,
> >
> >I have got a problem using a TIB_UpdateBar:
> >I have some TIB_Edits, a TIB_Datasource an a
> >TIB_Query in a form and it works well to insert
> >data.
> >
> >When I change a record and click the post button
> >of the TIB_Updatebar, the data is saved.
> >
> >But then I defined a hotkey which calls
> TIB_UpdateBar.BtnClick(ubPost)
> >so that the user does not need to use the mouse.
> >But when pressing the key I get the error message "Cannot
> post current
> >row".
> >
> >Anyone? :-(
>
>
> I think you are going to have to add more code to your hotkey
> handler, i.e.
> before you let it call the buttonclick, first test
> if (MyDataset.State in ([dssEdit, dssInsert, dssDelete])) then
> IB_UpdateBar.BtnClick(ubPost)
> else
> Beep;
> Or you could access the NeedToPost property of the ib_datasource, e.g.
is in dssBrowse State. But why?
I _am editing_ the dataset - I _am modifying_ the value of an TIB_Edit
connected to the dataset and the TIB_UpdateBar connected to the dataset
shows the post-icon in green so that I can post with one little click.
But if I press my hotkey which tries to post the dataset, the "cannot post
current row" error occurs because the dataset is in browse mode.
Maybe I am understanding it wrongly, but if I am editing a value, shouldn't
the dataset be in the dssEdit mode?
Christian