Geeks With Blogs

Connected Systems Chilled Out Blog Hanging stuff together in a meaningful way with some fun added

Sorry, not cracked the problems listed at the end of my last 64 bit dev blog. But added a new one.

My BizTalk project required the reading of data from an Excel spreadsheet – don’t ask….

Now previously I have used:  the Microsoft.ACE.OLEDB.12.0 provider. This allows you to treat the spread sheet as any normal data source. See sample below

  1: string strConn = "Provider=Microsoft.ACE.OLEDB.12.0;" + "Data Source=E:\\DEMO\\FileLocs\\Excel\\Data.xls;" + "Extended Properties=Excel 12.0;";
  2:             DataSet ds = new DataSet();
  3:             //You must use the $ after the object
  4:             //you reference in the spreadsheet
  5:             OleDbDataAdapter da = new OleDbDataAdapter("SELECT * FROM [Sheet1$]", strConn);


  Of course this time I get an error telling me that :


The problem, of course, is that the provider comes from Access install and as Office is 32 bit the driver just isn’t being recognised.

So to get this to work the solution is to target the project to run on x86 cpu’s.

To do this means changing the properties of the project:


So change from Any CPU to x86 and all is sweetness and light!

Not really 64 bit deving though…..

Now shall I install Office 2010 tech preview 64 bit and try again…mmmm..maybe…

Posted on Tuesday, August 25, 2009 7:39 PM | Back to top

Comments on this post: More 64 bit Dev fun…

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © BizTalk Visionary | Powered by: