How to click or run a macro inside the excel?

Hi all! i am getting text from website and writing it inside macro-enabled excel file. when writing is done i want ui path to click or run macro button. i used run spreadsheet macro but it didn’t work

You can open excel with Excel Application Scope then use Execute Macro (classic) activity and pass the macro name (the same one assigned to the button).
For example: Saveas if that’s the macro name in VBA.

Cheers

1 Like

Hi @elnur.isgandarov

Tu execute a macro in an excel file use invoke VBA activity in UiPath.

Use Excel application scope, open an excel in which you want to run an macro. Inside excel application scope use invoke vba activity. Save the macro in a notepad and pass that notepad path in that activity and give the macro name below.

You can also pass variables in a macro. if you require

Thanks!!

Just to double check. the name of the button inside VBA is “SaveFileWithAllRowsStandard”

but on the button itself is “Save as”

which one should i use?

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.