No Add-In Tab Though Add-In is Loaded and Working - vba

I wrote an Excel VBA add-in over ten years ago, which uses the old Commandbars to put a menu in Excel's Tools menu (in Excel 2003 and earlier) or in Excel's Add-Ins tab (in Excel 2007 and later). I've never had a problem with the menu appearing, in all versions of Excel from 97 through 2013.
But now a user says Excel Add-Ins menu not appearing for him in Excel 2013. Normally that means the add-in isn't loaded, but in his case the add-in is loaded and working. We know the add-in is loaded and working because the add-in adds user-defined worksheet functions, and those UDFs are working fine for him. But he wants to get to the add-in's menu and can't.
My googling showed that some people are having trouble with the Add-Ins menu in 2013, but I didn't find anything specific to this problem.
Yes, he's tried enabling the Add-Ins tab in Excel Options > Customize the Ribbon.
BTW this is an .xla add-in, not a COM add-in.
Any suggestions?

I have Excel 2010 and had the add-in tab disappear for MrExcel HTML add-in. I tried all types of suggestions - and finally found one that worked for me!
Go to the add-ins folder where you have your add in saved. Right click on the file, and select Properties. At the bottom of the General tab - if it says "Security" - check on the "Unblock" option.
Voila! My add-ins never disappear anymore!

Solved:
Solved this now but really weird solution if you enabled the Add-in whilst the Analysis ToolPaks were enabled it'd have the issue you above, but if you enabled the Add-in whilst the Analysis ToolPaks weren't ticked then went back in to it and re-ticked the Analysis ToolPaks it'd be fine and wouldn't disappear!
Was an extremely strange issue!
See Spiceworks

As far as I understood this is a problem with Excel 2013 (another attempt of the guys at Redmond to make our lives miserable with every update of their products). The workaround I've found is to include the following code into the ThisWorkbook module of the Addin:
Private Sub Workbook_Open()
Workbook_AddinUninstall
Workbook_AddinInstall
End Sub
Cheers!

I had similar issue with excel 2013. Add-in tab was missing. I went to Developer>>>Add-Ins and deselected the add-in I wanted. Click OK then repeat the process and select the same add-in. Click OK. The Add-In tab should appear.

See also https://www.excelcampus.com/vba/add-in-ribbon-disappears/
As of july 2016 the security settings in Excel disable the add-ins in the old default location. THe website shows how to set the directory to trusted status

I had a similar problem where two .xlam files that loaded and appeared in custom ribbon tabs in Excel 2010 didn't show up in the ribbon in Excel 2013 even though they were loading each time a workbook was opened. I tried all sorts of solutions - disabling the Analysis Toolpack, disabling and enabling the .xlam files, making sure the .xlam's attached XML file was up to date (I was thinking an MSO image I had in the XML code was no longer available in Excel 2013), but nothing worked. I eventually tried copying and renaming the .xlam file and enabled it in Excel and, strangely, it appeared in the ribbon.
I have no idea why it needed to be copied and renamed - it's almost like Excel 2013 needed a fresh copy of the .xlam file before it could show up. Very weird!

I've been looking for this answer for a LONG time and the previous code worked, but, for me, only with Workbook_Open() instead of Thisworkbook_Open()
Private Sub Workbook_Open()
Workbook_AddinUninstall
Workbook_AddinInstall
End Sub
Thanks for finding this!

I disabled the add-ins via the Developer tab, and then enabled them via File>Options>Add-Ins>Manage Add-Ins.
Voila!

You can Try by disabling macros with notification. (tried on 2016)
File->options->trust center->macro settings-> tick disable all macros with notification
It worked for me .

If I disabled and enabled, I could get the Add-Ins tab to appear, but every time I opened a document I had to repeat. This seemed to fix it for me:
File > Options > AddIns > Choose "XML Expansion Packs" > Go > Select "Microsoft Action Pane 3" > Attach > Ok

I have had similar problems with Excel 2016 (not with 2010 and 2017), and very strangely it was solved this way :
1) Desactivating the add-in
2) Quitting Excel
3) Activating the add-in
4) Going to File > Close (in French version : Fichier > Fermer)
And when I click "Close" the "Components" menu suddenly appear in Excel 2016 !
Good luck !

Had a similar problem in Excel 2010. Tried all the suggestions above, but to no avail. In the end it turned out that even though it was an .xll add-in, it somehow also was listed as a COM add-in. So going to File > Options > Add-In, then selecting Disabled Items from the list at the bottom of that window and enabling the add-in, worked for me. Now in the list of Active Application Add-ins it shows both the original Excel Add-in, and the unexpected COM add-in without location. Oh, and the tab is back of course. Go figure.

Related

After I save VBAProject.OTM and restart Outlook, macros can't work; the ribbon is greyed out

I'm using a few VBA macros in Outlook 2013 Professional Plus in Windows 7 Family Version. After a windows crash, my macro in outlook can't work.
ALT+F11 open VBA editor, find all ribbons are grayed out, no project in Project window. can't edit VBA in editor.
close outlook, delete %userprofile%\AppData\Roaming\Microsoft\Outlook\VBAProject.OTM, then restart outlook
ribbons are back to live, "Project1" show up in project window, i can insert new module and edit VBA and save macro.
after save, close outlook, confirm the new "VBAProject.OTM" is created with right time stamp.
restart outlook, back to 1, all ribbon grayed out, can't find macro/project, can't edit VBA.
I've checked with Google, but can't find similar issue or answers.
tried delete office and reinstall, still not working.
Some article mentioned (Digital Certificate for VBA Projects and Visual Basic for Applications), both are installed.
appreciate if you could provide some input.
thx a lot.
Some screen prints below:
All ribbons grayed out, can't load or edit VBA
Delete VBAProject.OTM then restart outlook

Running functions from Excel Add-Ins in vba, is there an easier way than using Run "mySub"?

I'm trying to create my first Excel Add-In for Excel 2010. Most of it is working, it's running from the ribbon buttons, but I'm having trouble addressing the Add-In's subroutines from my workbook's VBA code.
According to this answer on SO, it should be possible to simply use the syntax:
mySub
or
Call mySub
But this causes the error "Sub or Function not defined". I've only managed to run them this way:
Run "mySub"
or
Application.Run("myAddIn.xlam!mySub")
Is there a way to include the Add-In so I can address it the easy way?
The Add-In is already checked in the Tools->Add-Ins list, and has a unique name (CalcFunctions) which is different from its file name (CalculationFunctions.xlam). The Add-In file is on a different disk and I'm working on a server, but I don't expect that that matters.
(Posted on behalf of the OP).
Turns out I'm just dumb. I only set a reference to the Add-In in the regular Excel window. I assumed that was what people meant by Tools->References->Add-Ins (I use Excel in Dutch and there's no "Tools" menu). Anyway, the solution was setting a reference in that menu in the VBA editor window.
Here's how to add a reference in VBA:
ThisWorkbook.VBProject.References.AddFromFile refPath
With refPath being the full path to the file.
To be able to add references you need to have permission to edit the VBA project. You can enable this in excel settings->trust center->macro settings. If you're on a company pc it's likely the administrator has to set these settings for you.

Creating PowerPoint Add-Ins from VBA defined Macros

So I've created a Macro in a PowerPoint Presentation and I would like to make this Macro readily available to someone else. From what I have gathered, the best way to do this is to create an Add-in.
I have come across several articles stating to do the following, but I am still running into problems:
Open a new PowerPoint Presentation
Create a macro using VBA
Exit VBA, and save the Presentation as a .ppam
Under the Developer Tab, click on the "PowerPoint Add-ins" button
Click the "Add New..." option, and browse for your recently created
.ppam file
Click Load
Click Close
Click Add-ins
You should now see your new Add-in
I have done everything mentioned above and can even see the new Add-in when I select PowerPoint Add-Ins. I'm here because I can't find a way to run the new Add-in, and I don't want it to automatically load on startup or to interfere with the presentation by creating a button on the slides. As instead, I would like to allow the user to run this Add-in from the Ribbon.
Thoughts?
First, save as PPTM. THEN save as PPAM. If you only save as PPAM, you won't be able to go back and edit your code later to correct problems.
To launch your add-in from the ribbon, you must include RibbonX code (a type of XML) to your PPAM or PPTM (best to add it to the PPTM ... it'll become part of the PPAM automatically then).
There's an excellent book on RibbonX that'll save you hours of time:
http://www.amazon.com/RibbonX-Customizing-Office-2007-Ribbon/dp/0470191112
This is a good starting point if you don't want to buy the book:
https://blogs.msdn.microsoft.com/jensenh/tag/all-office-2007-ui-posts/
While you can manually unzip PPTM/PPTX/PPAM files and add the RibbonX code using any text editor, it's silly to do so. Instead use this free tool:
http://openxmldeveloper.org/blog/b/openxmldeveloper/archive/2009/08/07/7293.aspx

Listview on worksheet generates cannot insert object error Excel 2010

Hi I have an Excel 2003 application which has a listview embedded in the worksheet. It no longer works on Excel 2010.
I re-registered the ocx using regsvr32 C:\Windows\System32\MSCOMCTL.OCX as per advice.
This works for listviews on forms, but not for the worksheet.
Microsoft advises that Cannot insert object can be generated if the control is form specific and an attempt is made to add to the worksheet.
Can the listview be used in Excel 2010 on a worksheet
If so how?
Otherwise a rewrite will be required.
That happened to my Excel files using ActiveX or any sort of automation. The solution was confused at the beginning but the following link will help you.
Create a batch to remove cached control type libraries (extender files *.EXD) files from Windows
Opening each of the projects (Excel with macros)
Switch the file to design mode
Open VBA Code (Alt-F11) to edit any module and press from the main menu > Debug > Compile VBAProject
Switch back to Run Mode
Save and Close File
Reopen the file & test
Form Controls stop working after December 2014 Updates

XLAM / XLA Addins: is there a better way?

This post is about installing XLAM's without creating links. (Everyone hates links). Consider the trivial addin:
Public Function UDF_HELLO(x)
UDF_HELLO = "Hello " & x
End Function
Put this code and nothing else into a Module and save as "Hello.xlam" on the Desktop (and NOT in the default excel addins folder). Next, while HELLO.XLAM is still open, create a new XLSX workbook with the formula
=UDF_Hello("world")
in cell A1, which simply displays "Hello world" in that cell. Save the workbook and exit Excel. Now, if you reopen the workbook without the XLAM, Excel will complain about "links to other sources ...". Whether you click "Update" or "Don't Update", Excel will mangle the formula in cell A1 like this:
='C:\Documents and Settings\tpascale\Desktop\Hello.xlam'!UDF_Hello("world")
Very often this "forced-linkage" is NOT desirable. In my computing environment there is a lot of ad-hoc analysis and it makes no sense to impose an install regimen on every XLAM we throw together to solve the problem of the day. I just want to hand out XLAM files to users and let those users open them when they need them, WITHOUT having to worry about the slightest mis-step causing their formulas to get mangled.
QUESTION:
Is there a way to instruct Excel to NEVER construct external links for UDFs, and simply to use UDFs if they're loaded and return #VALUEs otherwise ?
I don't know of a way around this with .xla/.xlam add-ins.
But this issue does not occur with .xll add-ins.
These can be created in C using the Excel 2010 SDK, or in managed languages like VB.NET or C# using the free Excel-DNA library.
(Disclaimer: I'm the developer of Excel-DNA. This issue is one of the reasons I went with the .xll interface for making managed UDF add-ins.)
You can have them open the .xla file and have an Auto_Open procedure install the add-in.
http://www.vbaexpress.com/kb/getarticle.php?kb_id=693
After excel closes you can have the add-in uninstall itself.
oAddIn.Installed = False
You can give your add-in a setting for the user to not uninstall after every use by using a worksheet named something then have cell A1 equal to true or false.
I haven't tested this but hopefully it works for you.
This should work to resolve your issue though it does not instruct Excel regarding external links. I have tested it myself by creating the XLAM, saving it to my desktop, installing it in the Excel add-ins and then using it on a new workbook.
Steps:
Once you have saved the add-in, close it.
Go to Excel Options-->Add-Ins
In the Manage drop-down select Excel Add-ins and press 'Go'
In the 'Add-Ins'dialogue that appears click 'Browse' and navigate to
the add-in you just created. Select it and hit 'Ok'
If prompted to save the add-in in the add-ins folder, select 'No'.
Selecting 'Yes' may cause an error if the add-in file suffix does
not match the version of Excel being used.
Your add-in should appear in the 'Add-Ins available' scrollbox,
check its box and hit 'Ok'
Your add-in should now be active whenever you open Excel.
Test this by opening a new workbook and try using your UDF.
Best,
I usually solve this problem by:
Saving an XLA/XLAM file (outside Personal folder, of course)
Connect to it in Tools - Addins
Write pseudo macros in your current Excel file that links to those macros / functions in the XLA/XLAM file.
See the detailed instructions in my reply here.