Provider=Microsoft.ACE.OLEDB.12.0 under NAV2016 not working

SunsetSunset Member Posts: 201
I am trying to retrieve data from an access database, but keep getting met by Microsoft.ACE.OLEDB.12.0 not registered

I have verified that Excel will use the same connectionstring and will work. I have also downloaded and installed both the Office 2010 redistributable and the 2007 connectivity files from Microsoft, just to make sure. But still NAV2016 will not accept the command.
Although Excel is able to use it, it will not show up under powershell with: (New-Object system.data.oledb.oledbenumerator).GetElements() | select SOURCES_NAME, SOURCES_DESCRIPTION

Setup is:
NAV 2016 (Build 46621) running on a Win 10 machine
OleDBConnection defined as DotNet System.Data.OleDb.OleDbConnection.'System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'

Codelines:

OleDBConnection := OleDBConnection.OleDbConnection('Provider=Microsoft.ACE.OLEDB.12.0;Data Source=' + Database +';Persist Security Info=False;');
OleDBConnection.Open;

After it tries to open it will throw the error of "a call to System.Data.OleDb.OleDbConnection.Open failed with this message: The 'Microsoft.ACEOLEDB.12.0'provider is not registered on the local machine

Any hints as to what I am missing?

Don't just take my word for it, test it yourself

Comments

  • SunsetSunset Member Posts: 201
    Turned out that because I had installed the 32-bit AccessDatabaseEngine since my office is 32-bit NAV couldn't see the driver.
    Uninstalling both AccessDatabaseEngine and Office 2007 connectivity, and installing AccessDatabaseEngine_X64 was the solution.
    Don't just take my word for it, test it yourself
Sign In or Register to comment.