Excel ODBC Driver for Windows Server 2008 (64 Bit)
So I’m running Windows Server 2008 as a development workstation. I ran into some trouble with a custom .NET application that imports data from Excel files using the ODBC driver.
Error Message in .NET
ERROR [IM002] [Microsoft] [ODBC Driver Manager] Data source name not found and no default driver specified
We are using this ODBC connection string (found on connectionsstrings.com):
Driver={Microsoft Excel Driver (*.xls)};DriverId=790;Dbq=C:\MyExcel.xls;DefaultDir=c:\mypath;
After much research on the issue, it turns out the Excel ODBC drivers are 32 bit. So you need to change your Visual Studio platform to be x86 (to force 32bit) … mine was set to “Any CPU”
From what I can gather about the issue here, is that if your application is running in 64 bit mode, then when it creates an odbcConnection, that will also be running under 64 bit (makes sense so far) … so for any drivers that you have that are 32 bit they will not be accessible. Thus you get an error stating “data source name not found”
That’s it! Hope this helps.
For some light
reading on Windows Server 2008
One Response to “Excel ODBC Driver for Windows Server 2008 (64 Bit)”
Write a comment
You need to login to post comments!
Comment from enjos
Time June 26, 2009 at 10:47 pm
so as I,
I nearly search for all Internet,But there is already no idear,so disappointed!
and there’s only MSDA 64bit for windows server 2003!
I’ll find the answer go on;
if there’s any progress,I’ll comment again~
so If you have a way to solve it please tell me!
thanks a lot!