Name
Recordset.Open Method — (Versions 2.0, 2.1, 2.5, 2.6)
Synopsis
recordset.Open Source, ActiveConnection, CursorType, LockType, Options
The Open method opens a cursor within a Recordset object.
Arguments
-
Source(Variant) Optional. Indicates the actual data that is used to open the Recordset object. This can be a Command object, a SQL statement, a table name, a stored procedure, a URL, a filename, or a Stream object that contains a previously persisted Recordset object.
-
ActiveConnection(Variant) Optional. Specifies either an open Connection object or a connection string to be used when the Recordset object creates its own Connection object.
-
CursorType(CursorTypeEnum) Optional. Indicates the type of cursor that is to be used when opening the Recordset object. By default this value is
adLockReadOnly.
-
LockType(LockTypeEnum) Optional. Specifies the locking to be used on the opened Recordset object. The
adLockReadOnlyenumeration value is the default value for this argument.
-
Options(Long -- CommandTypeEnum and ExecuteOptionEnum) Optional. Specifies the type of data that is to be specified by the Source argument; additionally, can indicate that the Recordset object is to be opened asynchronously. The default value for the Options argument if a Command object is not the source of the Recordset object is
adCmdFile.
Description
The Source, ActiveConnection, CursorType, and LockType arguments have matching properties within the Recordset object. If the arguments are omitted in the Open method ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access