Ado|connection ConnectComplete and Disconnect (ConnectionEvent) method
The ConnectComplete method is invoked after the connection begins. The Disconnect method is called after the connection ends.
Grammar
ConnectComplete perror, adstatus, pconnection
Disconnect adstatus, pconnection
Parameters
Perror the Error object. It represents an error that occurs when the value of the adstatus is adstatuserrorsoccurred, otherwise it is not set.
Adstatus EventStatusEnum value, always returns adStatusOK.
When ConnectComplete is invoked, the parameter is set to adStatusCancel if the WillConnect method has already requested that a pending connection be canceled.
Set this parameter to adStatusUnwantedEvent before returning any methods to avoid subsequent notifications. However, closing and reopening Connection can cause these events to occur again.
Pconnection the Connection object to which the event is directed.