AddIn - Calling functions from VBA

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I've written an Addin, added it to the list of available addins and installed
it. I can use the functions within the AddIn within Excel worksheets. What
I would also like to be able to do is call the function from VBA. How can I
do this?

Thanks,

Graham
 
Graham,

Set a reference to your Add-in through the VBE, Tools, References....

HTH,
Bernie
MS Excel MVP
 
Bernie,

Thanks for your note. I unfortunately get a error message "Name conflicts
with existing module, project or Object library". Any ideas what I have to
rename in my addin to prevent me referencing it?

Thanks Graham
 
Graham,

Excel does references by "Project name", which doesn't change even if the workbook name is changed.
The default is VBAProject, so you probably have a whole bunch of VBAProject's. To change the name
of your add-in, press F4 to open the properties window, select the add-in in the Explorer window,
and change VBAProject to something unique, like "MyVBAAddIn"

HTH,
Bernie
MS Excel MVP
 
Back
Top