Subject | Re: Problem using TIB_Query |
---|---|
Author | stanw1950 |
Post date | 2003-08-22T17:14:58Z |
If you're desperate, you could put in the following code in the
query's OnStateChange procedure:
if ((Query.State = dssEdit) or Query.State = dssInsert)) then
UpdateBar1.Buttons[ubEdit].Visible := false
else
UpdateBar1.Buttons[ubEdit].Visible := true;
Using Enabled instead of Visible (a cleaner way of doing it) doesn't
work.
--- In IBObjects@yahoogroups.com, "Franky Brandt"
<franky.brandt@e...> wrote:
query's OnStateChange procedure:
if ((Query.State = dssEdit) or Query.State = dssInsert)) then
UpdateBar1.Buttons[ubEdit].Visible := false
else
UpdateBar1.Buttons[ubEdit].Visible := true;
Using Enabled instead of Visible (a cleaner way of doing it) doesn't
work.
--- In IBObjects@yahoogroups.com, "Franky Brandt"
<franky.brandt@e...> wrote:
> Hi,that if
>
> i recently converted our applications from Delphi 4 to Delphi 7.
> On a few forms i have a problem with TIB_Query.
> There is a update bar connected to the query and the problem is
> you click the insert of the updatebar fast after a few times i getwhen the
> errors because some fields that must have values do not have values.
> The query has beforepost, afterpost , beforeinsert and afterinsert
> events.
> The fields get their default values in the after insert event which
> works fine, except when you insert very fast.
>
> So it seems like the inserting from the updatebar happends even
> previous insert has not finished doing all the events yet..
> I have the same when i do a append myself from a button.
> Any ideas?
>
> May the source be with you
>
> Franky