Assigning a command button to a macro

G

Guest

OK. I know how to record a macro, but how do I assign (attach) that macro to
a command button so all I have to do is hit the button and the macro will
execute? Help is appreciated. Thanks.
 
J

JE McGimpsey

If the button is from the forms toolbar, right-click the button and
choose Assign Macro.
 
B

Bob I

Is it a custom button on the Toolbar? Open Customize and r-click the
button and pick assign macro.
 
G

Guest

Both of the replies said essentially the same thing. However, I can't find
where it says "Assign Macro". I'm using the command button on the toolbar, I
right click as you said...I think...I guess I'm just a dummy. Do I right
click on the command button while still on the toolbar...all I get is the
toolbar modification list, or do I put the command button on the worksheet
and then right click...then nothing happens.
 
B

Bob I

Open Customize, (either Tools Customize, or r-click toolbars, Customize)
then r-click the Custom button you put in the toolbar.
 
G

Guest

OK. I managed to get the smiley face command button on the toolbar and
assigned the macro to it. Now...how do I get my button or smiley face with
the macro attached down someplace on my worksheet? It won't click & drag.
 
B

Bob I

If you want a button in the spreadsheet, then you need the "Control
toolbox" button. Open "control toolbox", click command button, draw the
button, r-click the button, View Code, paste the macro contents into the
"click command"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top