|Subject||Re: [IBO] ib_connection.BeforeDisconect|
> Hi Dominik,aren't
> Dominik Murk wrote:
> > IBO 4.2.Eb, Delphi6 Enterprise.
> > Before I close my form I call IB_CONNECTION.DISCONNECT.
> > I do have 2 events: OnBeforedisconnect and OnAfterDisconnect but they
> > executet becouse in IBA_Connection.imp it says: 'if not ( csDestroyingin
> > ComponentState ) then ...' and my events isn't called becousecsDestroying
> > is in ComponentState.csDestroying
> > Is that ok and if it is do i have to call manualy this events?
> > Thanks,
> > Dominik Murk
> it seems you call IB_CONNECTION.DISCONNECT in the OnDestroy handler of
> your form. Try to do it in OnCloseQuery or OnClose instead, as
> is not (yet) in ComponentState at that time. (and don't free your formswith
> Free but with Release as this will handle events while closing/destroyingThat was that (OnClose).
> the form correctly)
> regards & hth,