This is basic, but did you create the DSN through your Data Sources? If so, did you test the connection? Did the connection work?
If you answered yes to all three of these, then I am not sure where to start, other than your UID and PWD.
The way I handle this sort of connection would be:
Dim stUID As String = "****"
Dim stPWD As String = "****"
Then ...
Dbs = connect.OpenDatabase("", False, False, _
"DSN=Bulletin_Boards;", stUID, stPWD)
I have done this in VBScript, and I had to create the connection first, then I used this syntax...
Set objConnection = CreateObject("ADODB.Connection")
objConnection.Open "DSN=AssetManagement;", strUserName, strPassword
I know these are different connection types, but please note the difference in syntax surrounding the UID and PWD.
The connection may be failing because you are not properly passing these credentials.
mmcdonal
|