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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ADO - SQL Connection In Access

Status
Not open for further replies.

Paladine

Technical User
Sep 16, 2001
26
CA
Hey folks, hope someone can help. I am not a novice to Access, but to ADO use I am. Just learning infact. I am trying to connect to an SQL database. The problem is this; In the attempt to run my connection code I get Runtime Error 426, ActiveX object can not be created and the following line looks like this that is highlighted.

Set adoConn = New ADODB.Connection

The code starts like this (in a sub)
Private Sub ADOConnect()

Dim strConnect As String
Dim adoConn As ADODB.Connection
Dim adoError As ADODB.Error
Dim adoErrors As ADODB.Errors
Dim strADOError As String

Then the line in question. MS ADO Library 2.5 is referenced.

Thanks

Troy
 
Try to use
Dim adoConn As New ADODB.Connection ________
George, M
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top