Connect MS access database from MS excel - Run-time error '3706' Provider cannot be found.
I am a new for VBA programer.
Basiclly I want connect MS access database from MS excel.
I use MS access 2010 and MS excel 2010 at Windows XP.
But I get an error say:
Run-time error '3706' Provider cannot be found. It may not be
at line: oConn.Open sConn
I checked the C:\Program Files\Common Files\Microsoft Shared\OFFCE14\ACEOLEDB.DLL
the file ACEOLEDB.DLL is there.
And I already added 'Microsoft ActiveX data Object 2.8 Library' refrence
Please tell me what is wrong.
Thanks a lot.
The following is my code:
Sub TestDB() Dim oConn As ADODB.Connection Dim oRs As ADODB.Recordset Dim sConn As String Dim sSQL As String Dim StrDBPath As String StrDBPath = "C:\Program Files\Allstate I.T\New Business Report\BrovadaActivity.mdb" sConn = "Provider=Microsoft.ACE.OLEDB.12.0;" & _ "Data Source=" & StrDBPath & ";" & _ "Persist Security Info=False;" ' Open a connection. Set oConn = New ADODB.Connection oConn.Open sConn ' Make a query over the connection. sSQL = "SELECT count(*) FROM [dbo_stats];" Set oRs = New ADODB.Recordset oRs.Open sSQL, oConn, adOpenStatic, adLockBatchOptimistic, adCmdText MsgBox oRs.RecordCount ' Close the connection. oConn.Close Set oConn = Nothing End Sub
Are you on a 64-bit machine? Try install the 32-bit drivers of the Database Engine 2010 Redistributable.
Look here. http://www.connectionstrings.com/the-microsoft-ace-oledb-12-0-provider-is-not-registered-on-the-local-machine/
frnd u takes wrong refference for ace.12.0 connecion string
first unselect that refference & select refference of
'Microsoft ActiveX data Object 6.0 Library'
microsoft DAO 3.5 REFFERENCE THEN TRY & RETRIVE VALUE
DINESH KANSE.....FRM INDIA.........
IF ITS USEFUL THEN MAIL ME @ DINESH_KANSE@REDIFFMAIL.COM
Connection to Access DB not working on new 2016 server.
Corporation updated my server and i started getting this error (provided from the server team): GET, /page/pages/MarketMatrix-2.asp, |236|800a0e7a|Provider_cannot_be_found._It_may_not_be_properly_installed.,0 votes0 answersJim Schwetz4 days ago
Assist with AHK to send / receive queries to MSAccess
Has or does anybody have information about working in "AHK" "Auto Hotkey" and connecting to an access database? Have found this link: https://github.com/IsNull/ahkDBA0 votes0 answersBarry Pettis1 month ago
connections not work in php
I am trying to connect an access 97 database from php, I have tried three ways methods and none works for me: $db = 'c:/VENTAS.MDB'; $odbcname = "ventas_dsn_sistema";0 votes0 answerscarlos col2 months ago
Connection String Not Working
I am new to SQL Connection strings. We recently migrated from SQL Server 2008 32 bit to SQL Server 2017 64 bit. The database I am using is an Access 2010 32 bit and we upgraded to Access 2013 32 bit. I believe the connection string that was being used for SQL Server 2008 32 bit was0 votes0 answersTheresa Draper5 months ago
Need connection string for Office 2019
I wrote a VB .NET program using VS17 that opens Excel files and loads the data into an Access database. For .xls files, I use the connection string: Provider=Microsoft.ACE.OLEDB.12.0;Data Source= ...;Extended Properties Excel 8.0;1 vote2 answersMark Cykowski7 months ago
Macro ne fonctionnent pas avec le runtime access
Bonjour et merci voici mon besoin j'ai un fichier excel qui me permet de gere mes contact depuis un userform dans le quel il y a des textbox et une combobox qui a pour base une table access0 votes0 answersM'chi7 months ago
Excel VBA ERROR ODBC connection failed
Hi, it is working in Excel-32 bit version, but not working in excel-64 bit. I have a linked table in ms-access which is linked to a sql server table, and when I am trying to fetch the data in excel via VBA from ms-access linked table the error message "ODBC connection failed" showing.0 votes1 answerKashif Khan8 months ago
Interbase ODBC to Access with foreign characters
I have a legacy Delphi database, with an application written in Borland Pascal. It's an old system, running on a virtual XP box, since it won't run on anything newer.0 votes0 answersPete D8 months ago
User Supplied OLEDB Password
Is it possible to supply a database password that is let's say supplied when the user logs into the website. Example "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Users\MyName\Documents\mywebsite_assets\database\database.mdb; Jet OLEDB:Database Password=" + strPassword0 votes0 answersSteve Hammockon Sep 29, 2018
Simplest way to get ADO.NET conection string for mdb database
I'm learning ADO.NET and have been stuck for DAYS trying to get a connection string for a plain, vanilla .mdb database. I've been trying potential connection strings and permutations from this site but NOTHING works; the database connection is never opened.0 votes1 answerAnonymous useron Aug 25, 2018
- Load more posts