Executing Macro with parameters over buttons
Posted: Fri 19. Oct 2018, 11:43
Hello,
I try to send CAN message, which content is calculated by VB script. The script works and can be started over a button of the control panel.
Now I try to achieve that all existing commands can be send via buttons. The command generation use a common logic, that I have implemented in a separate function with parameters.
Until now I did not manage to start this control function with parameters by clicking on a button. How can this be done?
Calling the macro with parameters in the command execute field of the button (like "command 0, 1, 3") did not work. My second approach was to write macros for each button and call the control macro with fix parameters. This works, if the control function and call operation is in the same file. But for this I have to copy the control function in every macro, which is a maintenance hell.
Is there a possibility to call a Macro from another file?
I try to send CAN message, which content is calculated by VB script. The script works and can be started over a button of the control panel.
Now I try to achieve that all existing commands can be send via buttons. The command generation use a common logic, that I have implemented in a separate function with parameters.
Until now I did not manage to start this control function with parameters by clicking on a button. How can this be done?
Calling the macro with parameters in the command execute field of the button (like "command 0, 1, 3") did not work. My second approach was to write macros for each button and call the control macro with fix parameters. This works, if the control function and call operation is in the same file. But for this I have to copy the control function in every macro, which is a maintenance hell.
Is there a possibility to call a Macro from another file?