Is there a way of calling a macro from within another macro?
Example
Sub Button1_Click()
For a = 1 To 10000
Range("A1") . Value = a
Next a
' Would now like to run the macro which is behind Sub Button2_Click()
End Sub
Is there a way of calling a macro from within another macro?
Example
Sub Button1_Click()
For a = 1 To 10000
Range("A1") . Value = a
Next a
' Would now like to run the macro which is behind Sub Button2_Click()
End Sub
Yes,
put the name of the macro within your macro
Sub MyMacro1()
MyMacro2
End Sub
Regards,
Peo Sjoblom
"grahammal" <[email protected]> wrote
in message news:[email protected]...
>
> Is there a way of calling a macro from within another macro?
>
> Example
>
> Sub Button1_Click()
> For a = 1 To 10000
> Range("A1") . Value = a
> Next a
> ' Would now like to run the macro which is behind Sub
> Button2_Click()
> End Sub
>
>
> --
> grahammal
> ------------------------------------------------------------------------
> grahammal's Profile:
http://www.excelforum.com/member.php...o&userid=20336
> View this thread: http://www.excelforum.com/showthread...hreadid=478781
>
Works perfectly.
Thanks a million.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks