Accessing Excel 2007 Binary (.xlsb) via OleDb ACE

后端 未结 1 1598
南方客
南方客 2021-02-15 16:47

I found the Excel 2007 Binary format (with extension .xlsb) perfectly suitable for my needs, since it\'s fast to load and very compact. I deliver a bunch of reports in Excel t

1条回答
  •  独厮守ぢ
    2021-02-15 16:50

    I know this is old post. I came across this issue few days ago and after lots of struggling, I'm able to resolve it. Hope it can help someone.

    In my case, I have the same exact error:

    This file was created in a previous beta version of Excel 2007. Open the file with Excel 2007 to save it to the most recent version of the Excel 2007 file format before opening the file in Access 2007."

    This happen when I'm trying to open my OldDB Connection. I suspected it was due to my connection string syntax or value issue but nothing work after massive amount of changes.

    I had the following installed in my machine:

    1) Microsoft Access database engine 2010 Version 14.0.7015 (Get it from here)

    2) Microsoft Office Access database engine 2007 Version 12.0.4581 (Get it from here)

    And here is my connection string that causes the error to happen:

    "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Project\Excel1.xlsb;Extended Properties='Excel 12.0;HDR={1}'"
    

    And then I found this that resolve my struggles:

    Microsoft Office Access Runtime and Data Connectivity 2007 Service Pack 2 (SP2).

    I just need to download, run it and reboot my machine. And then voila, I'm able to open my OleDB connection without that error.

    Hope this will help.

    0 讨论(0)
提交回复
热议问题