Any way to load a ribbon stored in an add-in? (1 Viewer)

burma

Member
Local time
Today, 06:00
Joined
Jan 17, 2024
Messages
50
In the following add-in, if you open it up stand-alone, you can see the ribbon it contains. But if you install it, the ribbon doesn't display even after the add-in is loaded. Is there a way to load the ribbon dynamically in VBA when it's installed? Thx
 

Attachments

  • AddinTest.zip
    30 KB · Views: 29

Josef P.

Well-known member
Local time
Today, 15:00
Joined
Feb 2, 2023
Messages
826
An Access add-in is not loaded when Access is started. Therefore, its ribbon tab is also not loaded.
The add-in itself (more precisely: a function of the add-in) can be started with VBA (from main application).
Application.Run "PathToAddInFile\FileNameWithoutFileExtension.StartFunction"

Workaround: use a COM add-in.
Note: I created a COM-Add-In with twinBasic, with which I can start functions from different Add-Ins.

[OT: UsysReginfo]
Use |ACCDIR\AddinTest.accda instead of C:\Users\T\AppData\Roaming\Microsoft\AddIns\AddinTest.accda
 
Last edited:

burma

Member
Local time
Today, 06:00
Joined
Jan 17, 2024
Messages
50
An Access add-in is not loaded when Access is started.
I realize that but what about once the add-in is loaded? Can the add-in's ribbon be loaded once the add-in is loaded?
The add-in itself (more precisely: a function of the add-in) can be started with VBA.
Application.Run "PathToAddInFile\FileNameWithoutFileExtension.StartFunction"
I don't understand this. My ribbon xml has this Expression: =msgbox("Add-in loaded"). But even though the add-in is loaded, its ribbon still is not displaying. I was wondering if there was a way to load the add-in ribbon with vba code.
Workaround: use a COM add-in.
Note: I created a COM-Add-In with twinBasic, with which I can start functions from different Add-Ins.
I will check this out, thanks. I would still like to be able to load the add-in's ribbon without using COM though, if possible.
 
Last edited:

isladogs

MVP / VIP
Local time
Today, 14:00
Joined
Jan 14, 2017
Messages
18,225

Josef P.

Well-known member
Local time
Today, 15:00
Joined
Feb 2, 2023
Messages
826
You would need the same option for Access add-ins as for COM add-ins to load additional tabs to the existing ribbon.
I have little hope for an implementation into Access. ;)

I use my COM add-in for developer add-ins.
For add-ins that extend an application (for the user), I build the button into the application ribbon and use it to start the required add-in function.
 
Last edited:

AHeyne

Registered User.
Local time
Today, 15:00
Joined
Jan 27, 2006
Messages
92
Ribbons are loaded when an application starts. If you create a new ribbon using code, you have to restart Access to view the new ribbon.
Well, there is also "Application.LoadCustomUI"...
 

Users who are viewing this thread

Top Bottom