Why can't Excel load the excel-dna addin?
Asked Answered
P

2

5

The error is:

The file you are trying to open, 'ExcelDna.xll', is in a different format than specified by the
file extension. Verify that the file is not corrupt and is from a trusted source before opening the file.

Prepossess answered 29/6, 2011 at 22:45 Comment(1)
Never mind, I tried loading the ExcelDna64.xll (I'm on 64-bit Office) and that helped. A related symptom was that if I said 'Yes' to the above dialog, upon opening the XLL via File->Open, I'd get the Text Import Wizard. You'd think Microsoft could detect the version the add-in is compiled for and complain more specifically.Prepossess
S
8

Yes - this is exactly the behaviour you get when an .xll add-in has the wrong 'bitness' for the Excel process. For Excel-DNA you need to use a copy of ExcelDna.xll for 32-bit Excel versions (running on 32-bit or 64-bit Windows), and a copy of ExcelDna64.xll for the 64-bit version of Excel 2010.

Note that on all versions of Windows (both 32-bit and 64-bit) the recommended and default installation of Office is the 32-bit version.

Stilted answered 30/6, 2011 at 8:48 Comment(1)
This helped me. I didn't realise my workplace had helpfully moved us from 32 bit Excel to 64 bit on a machine change. Thanks!Sheri
D
3

I've just had exactly the same problem, but NOT because of using DNA64. In my case the problem appeared when I was loading the XLL from C:\Temp\[blah]\myXll.xll If I copied the xll (and related folders) to C:\Program Files (x86)\[blah]\ then it worked fine.

Dever answered 24/4, 2012 at 12:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.