[Macro], [Arg1], [Arg2],…, [Arg30])
Macro: It is an Optional parameter. It is used to run the macro.
Arg1 to Arg30: It is an Optional parameter. It is used to passed to the function.
In the above syntax Application represents object and Run is the method of Application.
VBA Run Application Method: Example 1
Please find the below example for Run method of application object in excel VBA.
VBA Run Application Method: Remarks
Please find the below remarks of Run method of application object in excel VBA.
• We cannot use named parameters in this method.
• We cannot pass objects as parameter to procedures by using run method.
VBA Run Application Method – Instructions
Please follow the below steps to execute the VBA code to save the excel file.
Step 1: Open any existing Excel Application.
Step 2: Press Alt+F11 – This will open the VBA Editor.
Step 3: Insert a code module from then insert menu.
Step 4: Copy the above code and paste in the code module which have inserted in the above step.
Step 5: Now press F5 to execute the code.