Run macro Version 9 (Net)
Action group: Excel
Description
The action runs the macro.
Action icon

Settings of parameters
Property | Description | Type | Filling example | Mandatory field |
Parameters |
Context | Action context for working with an Excel document | Robin.Excel | Excel context | Yes |
Macro name | The name of the macro that will be run | Robin.String |
| Yes |
Special conditions of use
None.
Example of use
Tasks
There is an Excel-document "Test.xlsm".

Run a macro to count the number of records on a page.
Solution
- For any actions with a specific Excel-document, you should first open the document, create its unique identifier (Context), so that further actions can be applied to a specific document. Open the document "Test.xlsx".
- Run the macro.
- Save the document.
Implementation
- Assemble a robot scheme with the actions:

- Set the "Open" action parameters (see action description "Open").

- Set the "Run macro" action parameters.

- Set the "Save" action parameters (see action description "Save").

- Run the robot by clicking "Start" in the top panel.
Result
The document contains the result of the macro execution.

