The "Run Excel macro" Action executes a macro stored in a book.
It is useful for utilizing existing macro assets and for performing operations not supported by Power Automate Desktop, It is useful for utilizing existing macro assets and for performing operations that are not supported by Power Automate Desktop.
How to use.
First, set up the Launch Excel Action action and specify the Excel file in which the macro will be executed.
If you want to use macros that are external to the book you are opening, such as personal books or add-ins, Turn ON "Load add-ins and macros".
For macros in macro-enabled books, it will work even when OFF.
Drag "Run Excel Macro" from "Actions", "Excel", "Advanced" onto the workspace.
Specify the target Excel file.
Specify the Variables produced for the Launch Excel Action.
Specify the macro name and arguments to be executed, separated by a separator.
Specifying "Main;B3;ABCD" specifies "B3" and "ABCD" as arguments to the Main macro.
The Main macro we will use sets the value of the second argument in the first argument cell.
Public Function Main(address as string , value as string)
Range(address).Value = value
Main = "Completed."
Not present in this Action.
If you want to receive the result of a macro, set the result of the macro to a cell and
Retrieve that cell with Read from Excel Worksheet Action.
Error handling is performed as needed.
Failed to run macro
Occurs when an error is made in the specification or the macro fails to execute.
For those who want to learn Power Automate Desktop effectively
The information on this site is now available in an easy-to-read e-book format.
Or Kindle Unlimited (unlimited reading).
You willl discover how to about basic operations.
By the end of this book, you will be equipped with the knowledge you need to use Power Automate Desktop to streamline your workflow.