adoConnState
Previous Topic  Next Topic 

Synopsis:

       state=adoConnState(handle)

Arguments:

       handle - The connection handle.


Description:   This function returns the underlying state of the ADO _Connection object and can be used to determine when an asynchronous function has completed (Especially useful in non-blocking mode (see adoBlockMode()).


The state returned will be one of the enumerated state values as defined in the ado.inc file as follows:


Constant

Value

Description

adStateClosed

0

The object is closed

adStateOpen

1

The object is open

adStateConnecting

2

The object is connecting

adStateExecuting

4

The object is executing a command

adStateFetching

8

The rows of the object are being retrieved


Returns:   Returns the underlying state property of the ADO _Connection object or a negative error code.   If ADOERR_COMERR is returned, then the underlying ADO error can be obtained by calling adoLastError()