Problem Loading XLL Via VBA

Aug 30, 2010 at 8:08 PM

I have been automating Excel using the COM interface and have had trouble getting addins to load this way. To be more explicit, I create an Excel instance using win32com with Python, then run several functions written in VBA which call functions exposed via ExcelDNA.

What I am attempting is programmatically (in VBA) referencing the addin like this:


Workbooks.Open ("c:\windows\addins\TSXL\TSXL.xll")

AddIns("TSXL").Installed = True


This fails with the error:

Run-time error '1004'

Could not load file or assembly 'ExcelDna.Loader' or one of its dependencies. The system cannot find the file specified.

Sep 1, 2010 at 9:47 AM


Do you try this with the ExcelDna.xll and ExcelDna.dna files in the Excel-Dna Distribution directory?

You might try calling the AddIns.Add method explicitly.

AddIns.Add("c:\windows\addins\TSXL\TSXL.xll").Installed = True