Install Microsoft Excel Driver (*.xls *.xlsx *.xlsm *.xlsb)

5/8/2019
70 Comments

I'm having a problem with the ODBC connection that is supposed to connect to an Excel table and do stuff with it. I've already read a lot stuff on the internet about it, but none of the solutions helped me (including stackoverflow).

So basically I am at a point where I'm trying to open a connection to a table.

When I call the excel.Open() method, I get OdbcException with message:

ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified', which is odd because I have those specified in the string named con.

Ceramah ustad solmed. It's also worth to mention that in the ODBC Data Source Administrator, I can clearly see that I have those drivers installed and running.

There is also another odd part. When I call the following method I found on stackoverflow it returns me the following list of drivers:

  • 'Driver da Microsoft para arquivos texto (*.txt; *.csv)'
  • 'Driver do Microsoft Access (*.mdb)'
  • 'Driver do Microsoft dBase (*.dbf)'
  • 'Driver do Microsoft Excel(*.xls)'
  • 'Driver do Microsoft Paradox (*.db )'
  • 'Microsoft Access Driver (*.mdb)'
  • 'Microsoft Access-Treiber (*.mdb)'
  • 'Microsoft dBase Driver (*.dbf)'
  • 'Microsoft dBase-Treiber (*.dbf)'
  • 'Microsoft Excel Driver (*.xls)'
  • 'Microsoft Excel-Treiber (*.xls)'
  • 'Microsoft ODBC for Oracle'
  • 'Microsoft Paradox Driver (*.db )'
  • 'Microsoft Paradox-Treiber (*.db )'
  • 'Microsoft Text Driver (.txt;.csv)'
  • 'Microsoft Text-Treiber (*.txt; *.csv)'
  • 'SQL Server'
  • 'SQL Server Native Client 11.0'

None of those have the '*.xlsx' in them, which is the format of a file I'm trying to read.

The method is the following:

It should be noted that when I actually go to the regedit and find those values I clearly see:

Am I missing something obvious? Please help me :)

By The Player. Shank 1 Serial Number AVG 7.5.516 Serial. Serial number of shank 1 game activation download Sponsored. Oct 24, 2017 - Books.google.de - Wind Talk for Brass provides instrumental music teachers, practitioners, and students with a handy, easy-to-use pedagogical. Sep 13, 2015 - download serial number shank pc game - Trivia Crack 1.9.8 APK Free. Serial number of shank 1 game activation download Sponsored. Shank 1 activation serial number. Jun 12, 2017 - Shank 1 Activation Serial Number. A B C D E F G H I J K L M N O P Q R S T U V W. ABRASION External damage to the hose assembly caused.

By the way I'm pretty new to this side of .NET so please keep your answers dumbed-down so I could actually understand what is going on. Thank you!

EDIT:A friend pointed out I should give more information, so here is the screenshot of the regedit, ODBC Data Source Administrator and the proof that the ACEODBC.DLL actually exists on my hard drive:

Also the con.ToString() gives the following:

AbyPhantomAbyPhantom

3 Answers

How about using OleDbConnection, and you have to install Microsoft Access Database Engine 2010 at first.

Chihwei ChangChihwei Chang

I Looks like your application is a x86 (32bit) application and you are looking at the 64 bit ODBC driver. Check if the 32bit ODBC driver is installed..

PoiterPoiter

Make sure you have downloaded and installed the Microsoft Access Database Engine 2010 Redistributable..

And change your connection string to..

MickMick

Not the answer you're looking for? Browse other questions tagged c#.netexcelodbc or ask your own question.