Solved

Provider not found with ado.net

Posted on 2011-03-02
6
414 Views
Last Modified: 2012-05-11
I am using this code to connect to an access database in vb2008 and using the adodb reference but it says:

"Provider cannot be found. It may not be properly installed."

I use the Jet provider in other programs on the computer so I know it is there.

Dim cn As New ADODB.Connection
        Dim rs As New ADODB.Recordset
        On Error GoTo ErrTrap

        cn.Open("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=e:\builtin.mdb;User Id=admin;Password=;")
        rs.Open("select * from TestCase", cn)
        While Not rs.EOF
            MsgBox(rs("EmailAddress").Value)
            rs.MoveNext()
        End While
        rs.Close()
        cn.Close()
0
Comment
Question by:onemorecoke
  • 4
  • 2
6 Comments
 
LVL 27

Expert Comment

by:planocz
ID: 35023764
Did you look in your refernces in that project to see if you really are seeing ADO?
0
 
LVL 3

Author Comment

by:onemorecoke
ID: 35023806
My reference should be ADODB.DLL right?  Seems like everything is good.  I use the same connection string in a VB6 program with no problems.
0
 
LVL 3

Author Comment

by:onemorecoke
ID: 35023834
Could it be a 32bit/64bit issue?  Started up a new project with just defaults so I am assuming it is 32bit.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 27

Expert Comment

by:planocz
ID: 35023943
You should be using something like this
Microsoft ActiveX Data Objects 2.8 Library
Are you using VS 2005 or 2008?
0
 
LVL 3

Accepted Solution

by:
onemorecoke earned 0 total points
ID: 35024614
I figured it out.  I had to force the configuration manager to be in x86 mode, then it started understanding the Jet provider.  I thought it would default to x86 but apparently not.
0
 
LVL 3

Author Closing Comment

by:onemorecoke
ID: 35067799
No one answered it correctly but I kept working on it
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
This video discusses moving either the default database or any database to a new volume.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now