ADO » Recordset » Source

Syntax:
string = recordsetobject.Source
recordsetobject.Source = string
Set recordsetobject.Source = variant

Sets or returns a string value that defines the data source for a Recordset object.

The Source property can set either a string value or a Command object reference to specify a data source for a Recordset object, or it can return a string value that identifies the data source for a Recordset.

You can only set the Source property if the Recordset object is closed. If the source is a Command object, then the ActiveConnection property of the Recordset object inherits the value of the ActiveConnection property of the Command object. The string can invoke an SQL statement, a stored procedure, or a table name.

Examples

Code:
rsChants.Open strQuery, , , adCmdTable
...
strCommand = rsChants.Source

See Also: