Subject | Re: Post/Cancel : (was [IBO] Rollbacks) |
---|---|
Author | Malcolm Smith |
Post date | 2002-09-06T06:34:35Z |
I think I better go back to the docs again, the code below is wrong. Any
tips while I go searching....
tips while I go searching....
>
> void __fastcall TdmSprite::qryGroupsAfterClose(TIB_Dataset *IB_Dataset)
> {
> if(transMaster->Started && !transMaster->InTransaction)
> {
> try
> {
> if(IB_Dataset->Modified)
> {
> // ask the user, then...
>
> transMaster->Post();
> transMaster->Commit();
> }
> else
> IB_Dataset->Cancel();
> }
>
> catch(...)
> {
> transMaster->Rollback();
> }
> }
> }
>
>