Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to set my connection string?
Message
From
16/01/2001 11:38:45
 
 
To
All
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
How to set my connection string?
Miscellaneous
Thread ID:
00464236
Message ID:
00464236
Views:
54
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.
Marc Levesque
La Prairie, Quebec (CANADA)
marc.levesque@videotron.ca
Next
Reply
Map
View

Click here to load this message in the networking platform