My code adds lots of extra menu items to the Excel menu bar. When the
workbook loads/exits, it resets the normal Excel menu bar.
Sub Reset_CommandBars()
' In case user has reset menus already
On Error Resume Next
With Application.CommandBars("CustomMenu")
.Visible = False
.Delete
End With
With Application.CommandBars("Worksheet Menu Bar")
.Reset
End With
On Error GoTo 0
End Sub
Thing is, I lose my Solver add-in the whole time. My way to get it back
is as follows:
Sub Restore_Solver_Menu_Item()
' Unload the solver add-in, and install it again to
' have it show under the Tools menu again.
AddIns("Solver Add-in").Installed = False
AddIns("Solver Add-in").Installed = True
End Sub
But what I really want to do is the following:
1) Check whether the solver add-in is activated or not.
2) If already activated, is the option in the Tools menu?
3) If not in the menu, add it.
Any ideas, anyone?