Reputation: 157
I am a newbie to using Excel DNA so please pardon if the question is off. I have an ExcelDNA project that I am trying to find the steps on how to publish and deploy on the user's machine. The Application is written in c# using vs2017 and is a class library that I installed the ExcelDna.Integration and Microsoft.Office.Interop.Excel DLLs. The application is small at this point it contains a class called RibbonControl which inherits from ExcelRibbon. In the RibbonControl class, there is an XML tag that declares buttons and onaction methods. This creates buttons in the Ribbon. The functions of the button just write data to the excel sheet using the Microsoft.Office.Interop.Excel DLL. I am not using an a vsto add in or anything just the Excel interop lib and Excel DNA. When building in Release mode the directory looks like this
My question is can I publish this application as is and if so how would I go about doing that. If not what do I need to to get this application published and deployed. Thanks
Upvotes: 5
Views: 3250
Reputation: 16907
The intention is that you now have two single-file packed add-ins:
These are the add-ins for the 32-bit and 64-bit versions of Excel respectively, and if everything is set up correctly, you need only redistribute these.
But you should first check that the EPPlus.dll was correctly packed and works, so I suggest you copy the appropriate packed add-in into a separate directory on your machine, and check that it works fine from there. If not, copy in the EPPlus.dll next to the .xll, and check again.
The EPPlus.dll dependency would not be packed if you didn't add the required <Reference Path=... Pack='true' />
line into your .dna file.
Once you have the packed add-in working right on your machine, those two files are all you need to distribute (or just one file, if you know the bitness of the Excel installation of the user).
To load into Excel - simplest is to copy the .xll to a convenient directory, then File -> Open from within Excel. Your ribbon should load and everything should work.
Then to install as an add-in that loads automatically, go to the add-ins dialog (either just press "Alt+t i", or navigate with File -> Options -> Add-Ins ... Manage: Excel add-ins) then browse to the .xll and select it.
Upvotes: 4