Adding a Macro to a Toolbar

Written by Allen Wyatt (last updated October 2, 2021)
This tip applies to Excel 97, 2000, 2002, and 2003


Excel is a very flexible program. You can configure it to work just about any way you can imagine. For instance, you can create a macro, and then add it to a toolbar. To do this, follow these steps:

  1. Choose Customize from the Tools menu. Excel displays the Customize dialog box.
  2. Make sure the Toolbars tab is selected. (See Figure 1.)
  3. Figure 1. The Toolbars tab of the Customize dialog box.

  4. In the list of toolbars, make sure there is a check mark beside the toolbar to which you want your macro added. The check mark ensures that the toolbar is displayed on the screen.
  5. Click on the Commands tab. (See Figure 2.)
  6. Figure 2. The Commands tab of the Customize dialog box.

  7. In the list of Categories, choose the Macros entry. Your macros should then appear in the Commands list.
  8. In the Commands list, select the macro you want assigned to a toolbar.
  9. Using the mouse, drag the macro from the Commands list to the location on the toolbar where you want it to appear.
  10. When you drop the macro, it appears on the toolbar.
  11. To add more macros, repeat steps 6 through 8.
  12. Click on Close.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the ExcelTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (2926) applies to Microsoft Excel 97, 2000, 2002, and 2003.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Running a Macro in a Number of Workbooks

Got a macro that you need to run on each of a number of workbooks? Excel provides a number of ways to go about this task, ...

Discover More

Cycling through Colors

Excel includes quite a few tools that are not normally accessible through the various toolbars. One such esoteric tool is ...

Discover More

Specifying Location for a Message Box

When writing macros, you may want to position a message box at a specific location on the screen. This can't be done in ...

Discover More

Program Successfully in Excel! John Walkenbach's name is synonymous with excellence in deciphering complex technical topics. With this comprehensive guide, "Mr. Spreadsheet" shows how to maximize your Excel experience using professional spreadsheet application development tips from his own personal bookshelf. Check out Excel 2013 Power Programming with VBA today!

More ExcelTips (menu)

Determining the Hour of the Day

Need to know the current hour of the day? You can derive the information in your macros by using the Hour function, as ...

Discover More

Filling a Range of Cells with Values

When writing a macro, you may want to fill a range of cells with different values. The easiest way to do this is to use ...

Discover More

Moving Macros from the Personal Workbook

Need to move a macro out of your Personal.xls workbook and into a regular workbook? You can do it using familiar editing ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 1 + 1?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


This Site

Got a version of Excel that uses the menu interface (Excel 97, Excel 2000, Excel 2002, or Excel 2003)? This site is for you! If you use a later version of Excel, visit our ExcelTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.