Databases Reference
In-Depth Information
adPropNotSupported
The property is not supported by the data provider.
adPropRequired
The user must specify a value for this property before the data source is
initialized.
adPropOptional
The property is optional.
adPropRead
The property can be read.
adPropWrite
The property can be set.
To illustrate, consider the PropertiesExample procedure shown in Example 17-3.
Example 17-3. The PropertiesExample procedure
Sub PropertiesExample( )
Dim rs As ADODB.Recordset
Dim cn As ADODB.Connection
Dim prop As ADODB.Property
' Set up connection
Set cn = New ADODB.Connection
cn.Provider = "Microsoft Jet 3.51 OLE DB Provider"
cn.ConnectionString = "Data Source=d:\BkAccessII\AccessCode.mdb"
cn.Open
' Open recordset
Set rs = New ADODB.Recordset
rs.Open "Names", cn, adOpenDynamic, adLockReadOnly, adCmdTable
For Each prop In rs.Properties
Debug.Print prop.Name
Next
rs.Close
cn.Close
End Sub
Search WWH ::




Custom Search