If I have recorded a macro and saved it as test1 and want to run the macro from a command button, how do I associate the saved macro test1 with the button? Thanks.
If I have recorded a macro and saved it as test1 and want to run the macro from a command button, how do I associate the saved macro test1 with the button? Thanks.
put the sheet in design mode by clicking the control toolbox toolbar upper
left button. Then double click on the command button or right click on it
and select view code. You will want to see code like
Private Sub CommandButton1_Click()
Test1
End Sub
or move all the code but the declaration and end statement in the Click
event.
--
Regards,
Tom Ogilvy
"sarasotavince" <[email protected]>
wrote in message
news:[email protected]...
>
> If I have recorded a macro and saved it as test1 and want to run the
> macro from a command button, how do I associate the saved macro test1
> with the button? Thanks.
>
>
> --
> sarasotavince
> ------------------------------------------------------------------------
> sarasotavince's Profile:
http://www.excelforum.com/member.php...o&userid=30237
> View this thread: http://www.excelforum.com/showthread...hreadid=499104
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks