[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'db' (#fcl)

TCustomConnection.BeforeDisconnect

Event triggered before a connection is closed

Declaration

Source position: db.pas line 1612

published property TCustomConnection.BeforeDisconnect: TNotifyEvent
  read FBeforeDisconnect
  write SetBeforeDisconnect;

Description

BeforeDisConnect is called before a connection is closed in TCustomConnection.Close. It can be used for instance to check for unsaved changes, to save thise changes, or to abort the disconnect operation: if an exception is raised during the event handler, the disconnect operation is aborted entirely.

See also

TCustomConnection.Close

  

Close the connection

TCustomConnection.AfterDisconnect

  

Event triggered after a connection is closed

The latest version of this document can be found at lazarus-ccr.sourceforge.net.