Data.Win.ADODB.TEventStatus

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

TEventStatus = (esOK, esErrorsOccured, esCantDeny, esCancel, esUnwantedEvent);

C++

enum DECLSPEC_DENUM TEventStatus : unsigned char { esOK, esErrorsOccured, esCantDeny, esCancel, esUnwantedEvent };

Properties

Type Visibility Source Unit Parent
enum public
Data.Win.ADODB.pas
Data.Win.ADODB.hpp
Data.Win.ADODB Data.Win.ADODB

Description

TEventStatus values indicate the success or failure of an operation.

Read TEventStatus values to determine the success or failure status of an operation that triggers an event. A TEventStatus value is passed to the handler for every event of the TADOConnection and TCustomADODataSet descendant. Each TEventStatus is directly equivalent to the ADO value with a similar name.

In some cases, the event handler status parameter may be assigned a value to alter the outcome of the occurrence that triggered the event. These cases are documented in the help topics for individual connection and dataset component events.

The EventStatus parameter of associated event handlers surfaces the ADO adStatus parameter of its events, which is of ADO type EventStatusEnum. If the operation executed without problem, the TEventStatus value returned is esOK. If the operation did not execute without problem, one of the other values is returned. For instance, esErrorsOccured is returned when the operation failed because of one or more error conditions.

TEventStatus consists of the five constants summarized in the following table:



Execute Option Meaning

esOK

Operation executed without problem.

esErrorsOccured

An error occurred during execution of the operation.

esCantDeny

A pending connection operation cannot be canceled. (Connection events only.).

esCancel

A pending connection has been canceled before it became active. (Connection events only.)

esUnwantedEvent

Set by the ADO method, prevents subsequent notification of the event.



See Also