Hi Everybody,
I try to retrive the field values of a selected table through ADO using
the following code.I am getting run time error:3265 and the filds list is
not displaying.Please let me know how to get the field names from the
table.
*************
Dim cnn As New ADODB.Connection
Dim cat As New ADOX.Catalog
Dim tbl As ADOX.Table
Dim i As Integer
cnn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=C:\linker.mdb;"
Dim rs As ADODB.Recordset
Set rs = cnn.OpenSchema(adSchemaColumns)
'Loop through the results and print
'the names in the debug window
Do Until rs.EOF
If rs.Fields("TABLE_COLUMNS") <> "VIEW" Then
Debug.Print rs.Fields("TABLE_COLUMNS")
End If
rs.MoveNext
*************
Thanks.
Loop