Execute a button from third party com add-In

abc_xyz

New Member
Joined
Jan 12, 2022
Messages
47
Office Version
  1. 2016
Platform
  1. Windows
I have installed a third party com add-in. It is a .vsto file format. The add-in has a Refresh All button. I want to execute that using VBA.
Is this even possible?
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
If that button has a shortcut key you could send that as command from VBA (Sendkey).
 
Upvote 0
A reminder:

Cross-posting (posting the same question in more than one forum) is not against our rules, but the method of doing so is covered by #13 of the Forum Rules.

Be sure to follow & read the link at the end of the rule too!

Cross posted at:

There is no need to repeat the link(s) provided above but if you have posted the question at other places, please provide links to those as well.

If you do cross-post in the future and also provide links, then there shouldn’t be a problem.
 
Upvote 0
It has to be dynamic so that it works for all the users. The position of the add-in may or may not be same for everyone.
If that button has a shortcut key you could send that as command from VBA (Sendkey).
 
Upvote 0
It is likely that the add-in vendor has exposed a COM call which you can invoke from VBA and will do the same thing as clicking on the ribbon button, eg. Application.Run "SomeNameInHere".

This will be the most straightforward option for you but the trick is knowing what name to use and whether any arguments need to be passed in. For example, Bloomberg has one called "RefreshAllWorkbooks". If you tell us what the add-in is, we might know it or be able to help you search; alternatively you could contact the vendor and ask them.
 
Upvote 0
It is likely that the add-in vendor has exposed a COM call which you can invoke from VBA and will do the same thing as clicking on the ribbon button, eg. Application.Run "SomeNameInHere".

This will be the most straightforward option for you but the trick is knowing what name to use and whether any arguments need to be passed in. For example, Bloomberg has one called "RefreshAllWorkbooks". If you tell us what the add-in is, we might know it or be able to help you search; alternatively you could contact the vendor and ask them.
It is Dealogic excel plugin. I did try using some combinations for the COM call method but it did not work.
 
Upvote 0
It is Dealogic excel plugin. I did try using some combinations for the COM call method but it did not work.


I'm not familiar with Dealogic so I'm afraid I can't help further. If there isn't any info in their documentation I would try contacting their helpdesk to see if there is a call available as that would be the easiest option.

It is possible to access and trigger ribbon components via the IAccessible interface, but that's a more complicated piece of work...
 
Upvote 0
I'm not familiar with Dealogic so I'm afraid I can't help further. If there isn't any info in their documentation I would try contacting their helpdesk to see if there is a call available as that would be the easiest option.

It is possible to access and trigger ribbon components via the IAccessible interface, but that's a more complicated piece of work...
Can this be done using UI Automation Library? If yes, could you please help me as I have zero knowledge about it?
 
Upvote 0
It should be possible to do this using the IAccessible Interface as suggested by Colin or using UI Automation.

What is the caption of this 3rd party addin button ? And, Is it a separate Tab like for example the Home Tab or is it a button under a Tab ?
If you post a screenshot of it, it should help us find a solution.
 
Upvote 0
It should be possible to do this using the IAccessible Interface as suggested by Colin or using UI Automation.

What is the caption of this 3rd party addin button ? And, Is it a separate Tab like for example the Home Tab or is it a button under a Tab ?
If you post a screenshot of it, it should help us find a solution.
Yes, it is a separate tab just like Home Tab. The tab is called Dealogic (caption). Under that tab there are multiple groups. Every group has multiple buttons inside it. The group name Refresh has the Refresh All button. Unfortunately, Im not allowed to post any snapshots. I hope this helps.
 
Upvote 0

Forum statistics

Threads
1,223,230
Messages
6,170,883
Members
452,364
Latest member
springate

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top