macro button

Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

Forum home » Delegate support and help forum » Microsoft Excel Training and help » Macro button

Macro button

resolvedResolved · Urgent Priority · Version Standard

Nick has attended:
Access Introduction course

Macro button


I have written several macros and I am using quick key's to run the macros, I would like to be able to use a button on the excel toolbar to run the macro instead. Can you please tell me how to add a button to a macro?

Cheers
NICK

RE: Macro button

Hi Nick,

Go to Tools -> Customise -> Commands tab.

In the categories list box, scroll down and select Macros. Then, in the 'commands' box, click and drag the 'custom button' onto any toolbar you like, then release the mouse button.

Don't close down the 'customise' dialogue box just yet - it needs to remain open for the next step.

Right-click the new button and choose Assign Macro. Then follow the dialogue box instructions to select your Macro and other options.

You can also change the button's icon by right-clicking the button -> Change Button Image.

Repeat the above procedure for any additional buttons you want to create (eg. if you have more than one macro).

Then close the 'Customise' dialogue box.

This will now allow you to press the newly created button whenever you want to run the Macro.

I hope this answers your question.

Regards, Rich

RE: Macro button

Thanks for the prompt reply Rich - much appreciated!


 

Excel tip:

Generate randon numbers

Some types of analysis require you to use randomly generated numbers. You can also use randomly generated numbers to quickly populate an Excel spreadsheet. There's an easy function you can use to do this automatically. Here are a few of the ways you can use it:

Type =RAND() in a cell to generate a number between 0 and 1.
Type =RAND()*100 to generate a number between 1 and 100.

View all Excel hints and tips


Server loaded in 0.09 secs.