Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ADODB and OpenSchema

Status
Not open for further replies.

miked123

Programmer
Nov 9, 2001
38
US
I'm trying to get a listing of Databases available from a SQL server.
I've built a ODBC Login form in Excel 2000 using ADODB connections. I can get all the table and field info about a database but I need the list of the Databases.

Here is my connection:

Set pADOcn = New ADODB.Connection
pADOcn.ConnectionString = "DSN=" & prDsnName & ";UID="
& prUserid & ";PWD=" & prPwd
pADOcn.Open
Here is my OpenSchema
Set rstSchema = pADOcn.OpenSchema(adSchemaCatalogs)

The recordset is empty.

Probably has something to do with the DSN inital catalog.
Can anyone shed some light?
Thank You


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top