Subject | Re: [IBO] Insert and Post |
---|---|
Author | Luiz Alves |
Post date | 2001-02-20T10:33:15Z |
Riho-Rene Ellermaa,
Insert,Edit and Delete call the event Before and After Post.
You can check in Before Post event for:
qry.State in [dssEdit,dssDelete,dssInsert] or someone this states and take
the appropriate action.
In After Post you can check for:
qry.PostedState in [dssEdit,dssDelete,dssInsert] or someone this states and
take the appropriate action.
Regards,
Luiz.
Insert,Edit and Delete call the event Before and After Post.
You can check in Before Post event for:
qry.State in [dssEdit,dssDelete,dssInsert] or someone this states and take
the appropriate action.
In After Post you can check for:
qry.PostedState in [dssEdit,dssDelete,dssInsert] or someone this states and
take the appropriate action.
Regards,
Luiz.
----- Original Message -----
From: Riho-Rene Ellermaa <r.ellermaa@...>
To: IBObject (E-mail) <IBObjects@yahoogroups.com>
Sent: Tuesday, February 20, 2001 5:12 AM
Subject: [IBO] Insert and Post
> I noticed that when I press Insert button in ActionBar, my BeforePost()
> method is also called. When I checked the IBO code there was indeed
SysPost
> function in Insert.
>
> Procedure TIB_Dataset.SysInsert;
> begin
> if CanInsert and not FInsertPending then
> begin
> SysBeforeInsert;
> FInsertPending := true;
> FWasSearching := ( State = dssSearch ) or ( Active and
FWasSearching );
> try
> SysPost( false, false );
> MasterToChildAction( mcaPost );
> ...
>
>
> Is this normal, or am I missing some parameters somewhere? In BeforePost I
> do some data checking and now the user gets errormessage even before he
has
> chance to do anything.
>
>
> Riho-Rene Ellermaa
> senior programmer
> Hansabank
>
>
>
>