Check if VBA Sub can be run to choose whether to run VBA Sub or code in add-in

Started by Visisthebest, June 12, 2020, 07:19:05 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Visisthebest

A Visio add-in can be much slower than Visio VBA especially when doing a ton of work handling shapes on the page (I have learned in this forum, thank you for all the help and advice!). Is it possible to let a Visio Add-in check whether a VBA Sub is available (and can be run given macro security settings) in the stencil and then decide whether to use the much faster VBA Sub rather than the code in the add-in for handling shapes on the page?

This would make possible a solution that runs on security-hardened corporate workstations (no macros allowed, run via the already installed digitally-signed add-in) and speedy execution on computers that use the safe setting of allowing only macros that have been digitally signed. (which I guess is a good security solution, allow macros yet stops almost all malware macros).
Visio 2021 Professional