Hi everyone,
I want to run a procedure of project in another Workbook (wb2) from current Workbook (wb1)
-This procedure was not created by me and too complicated for me to understand.
-This procedure has Arguments, like "Case 1","Case 2",etc
-I do have wb2 open
I was searching and found two approaches but I still don't know the code
Approach 1: Run procedure directly from current Workbook
Application.Run("wb2"."'!MacroName")
I tested and this code works with procedure without arguments, with arguments like the one i want to run it returns the error
I only want to run with Argument "Case 1"
Approach 2: the procedure I want to run is link to a button ( Button 1 )
I want to write a short Macro to Left Click that Button 1 so the procedure will run from there
Please help !
I want to run a procedure of project in another Workbook (wb2) from current Workbook (wb1)
-This procedure was not created by me and too complicated for me to understand.
-This procedure has Arguments, like "Case 1","Case 2",etc
-I do have wb2 open
I was searching and found two approaches but I still don't know the code
Approach 1: Run procedure directly from current Workbook
Application.Run("wb2"."'!MacroName")
I tested and this code works with procedure without arguments, with arguments like the one i want to run it returns the error
I only want to run with Argument "Case 1"
Approach 2: the procedure I want to run is link to a button ( Button 1 )
I want to write a short Macro to Left Click that Button 1 so the procedure will run from there
Please help !
Last edited: