Class Connection (ADODB VBA)

The class Connection represents an open connection to a data source.

Methods

BeginTrans - These transaction methods manage transaction processing within a Connection object as follows:.

Cancel - Cancels execution of a pending, asynchronous method call.

Close - Closes an open object and any dependent objects.

CommitTrans - These transaction methods manage transaction processing within a Connection object as follows:.

Execute - Executes the query, SQL statement, or stored procedure specified in the CommandText property.

Open - Opens a connection to a data source.

OpenSchema - Obtains database schema information from the provider .

RollbackTrans - These transaction methods manage transaction processing within a Connection object as follows:.

Properties

ConnectionString (Default member) - Indicates the information used to establish a connection to a data source.

Attributes indicates one or more characteristics of an object.

CommandTimeout indicates how long to wait while executing a command before terminating the attempt and generating an error.

ConnectionTimeout indicates how long to wait while establishing a connection before terminating the attempt and generating an error.

CursorLocation indicates the location of the cursor service.

DefaultDatabase indicates the default database for a Connection object.

Errors any operation involving ADO objects can generate one or more provider errors. As each error occurs, one or more Error objects are placed in the Errors collection of the Connection object. For details about handling warnings and errors in your ADO application, see Error Handling.

IsolationLevel indicates the level of isolation for a Connection object.

Mode indicates the available permissions for modifying data in a Connection, Record, or Stream object.

Properties contains all the Property objects for a specific instance of an object.

Provider indicates the name of the provider for a Connection object.

State indicates for all applicable objects whether the state of the object is open or closed.

Version indicates the ADO version number.

Errors - Contains all the Error objects created in response to a single provider-related failure provider.

Properties - Contains all the Property objects for a specific instance of an object.

Recordset - Represents the entire set of records from a base table or the results of an executed command. At any time, the Recordset object refers to only a single record within the set as the current record.