1

I am trying to turn a custom ribbon button I made into an add-in that others can use for any worksheet in Excel. I followed this StackExchange post on making a custom ribbon tab to make the ribbon button, and I have it successfully working within one workbook (one Excel Macro Enabled file).

How can I export the ribbon tab XML along with the VBA callback module so another user can use this in their Excel installation?

Thanks!

Community
  • 1
  • 1
Hari
  • 157
  • 2
  • 12
  • have you had a look at this? seems like it would suit your needs http://stackoverflow.com/questions/20764336/sharing-custom-macros-and-custom-excel-ribbon-with-others-via-sharepoint – ballsy26 Jul 01 '16 at 01:06
  • @ballsy26 That might help, but I don't think I'd be using Sharepoint for distribution. – Hari Jul 01 '16 at 01:44
  • yep, but in terms of moving the macros to an .xlam and distributing that instead, alternatively you can convert everything to vb.net and make a VSTO add-in which people can install – ballsy26 Jul 01 '16 at 01:47
  • @ballsy26 Ah, I see what you mean. I'll take another look, though dePatinkin might be right (I haven't had a chance to check). – Hari Jul 01 '16 at 01:54

1 Answers1

2

There are a few ways to do it. The simplest one is to put your .xlsm file in a known start-up folder like XLSTART.

To find the folders' location, in Excel:

  1. Go to File > Options > Trust Center
  2. Click Trust Center Settings...
  3. Go to Trusted Locations
  4. Put your file in one of the listed XLSTART or STARTUP locations.

The locations look something like this C:\Program Files\Microsoft Office\Root\Office<XX>\XLSTART\ for the whole computer, or like C:\Users\<User>\AppData\Roaming\Microsoft\Excel\XLSTART\ for the user.

When you restart Excel the file should be loaded automatically.

In addition: Saving your file as a .xlam will also make it behave as an add-in, and will not show the worksheet. You can find some information about the file type choice here Excel: Book or Addin.

dePatinkin
  • 2,239
  • 1
  • 16
  • 15