I use ADO and I want to access database by ODBC.
I tried the following (to access SQL Server database)
Dim cn As New ADODB.Connection
Const lcConnectString = "uid=pomuser;pwd=pompom;driver=SQL Server;" & _
"server=SQL_Server;database=pom;dsn=''"
loConnection.ConnectionString = lcConnectString
loConnection.Open
EVERYTHING WORKS FINE!
but also I want to access a Visual FoxPro database,
so how do I set my connection string when
driver name = Microsoft Visual FoxPro Driver
database name = Campagne
dsn has been created in ODBC named 'VFP Campagne'
uid is null
pwd is null
The driver is recognized but I got a run time error:
[Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr failed
Someone can help me please?
Thank you in advance.