Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, and 2013. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Assigning Macros to Graphics.
by Allen Wyatt
(last updated August 16, 2014)
You already know that Excel allows you to add graphics to your worksheets, such as pictures. You may not know, however, that you can assign macros to these graphics. With a macro associated with a graphic, the macro is executed whenever someone clicks on the graphic.
To assign a macro to a graphic, follow these steps:
Figure 1. The Assign Macro dialog box.
Save your workbook and test out your assignment by clicking on the graphic. The macro should run, as desired.
ExcelTips is your source for cost-effective Microsoft Excel training. This tip (9426) applies to Microsoft Excel 2007, 2010, and 2013. You can find a version of this tip for the older menu interface of Excel here: Assigning Macros to Graphics.
Save Time and Supercharge Excel! Automate virtually any routine task and save yourself hours, days, maybe even weeks. Then, learn how to make Excel do things you thought were simply impossible! Mastering advanced Excel macros has never been easier. Check out Excel 2010 VBA and Macros today!
Got some images that you want to appear in a worksheet based on the result displayed in a cell? Figuring out how to ...Discover More
The camera tool allows you to capture dynamic "pictures" of portions of a worksheet. If you want to use the camera tool from ...Discover More
Do you need to add a logo or other graphic to a bunch of worksheets? Here are a couple of short macros that can make quick ...Discover More
FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.