ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   ADO connection error (https://www.excelbanter.com/excel-programming/374009-ado-connection-error.html)

John T Ingato

ADO connection error
 
I am attempting my first attempt to connect to an Access database using ADO.
When I try to open the connection I get a run-time error -2147467259
(80004005) Could not find installable ISAM.

what the heck does this mean?
I have a book Excel 2003 VBA and followed the code to the T. Am I missin
something?


Sub init()

Dim Connection As ADODB.Connection
Set Connection = New ADODB.Connection
Connection.ConnectionString = ConnectionString

Connection.Open
MsgBox Connection.State = ObjectStateEnum.adStateOpen
Connection.Close


End Sub




Alok

ADO connection error
 
Hi,
There is probably something wrong with the connection string. Insert a line
before Connection.Open (Assuming the this is the line that is raising the
error)

Debug.Print Connection.ConnectionString

Then examine the ConnectionString that is printed - see if you can find a
problem with it. Let the newsgroup know and someone may be able to help.


"John T Ingato" wrote:

I am attempting my first attempt to connect to an Access database using ADO.
When I try to open the connection I get a run-time error -2147467259
(80004005) Could not find installable ISAM.

what the heck does this mean?
I have a book Excel 2003 VBA and followed the code to the T. Am I missin
something?


Sub init()

Dim Connection As ADODB.Connection
Set Connection = New ADODB.Connection
Connection.ConnectionString = ConnectionString

Connection.Open
MsgBox Connection.State = ObjectStateEnum.adStateOpen
Connection.Close


End Sub






All times are GMT +1. The time now is 11:12 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com