Moving Objects with a Chart

Written by Allen Wyatt (last updated March 11, 2023)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021


Irving created a chart and placed a text box on that chart. He also drew a line on the chart to serve as a reference for users. If he moves the chart, the text box and the line don't move with it. Irving wonders if there is a way to "lock" the text box and the line so that they move whenever he moves the chart.

There are two ways to approach this. First, you may want to consider how you are actually creating the text boxes and lines. If you select the chart before you create them, you'll notice that Excel makes some new tabs available on the ribbon. Click the Layout tab, and you'll notice an Insert Shapes group. You can select shapes and lines from these, and they become part of your chart and will move with it. (Use a rectangular shape in lieu of a text box; Excel allows you to add text inside the shape just as you would with a text box.)

If your text box and line are not part of the chart itself—if they can be moved outside the bounds of the chart by dragging them off the chart—then you can "lock" them in position by grouping objects. Follow these general steps:

  1. Click on the text box to select it.
  2. Hold down the Shift key as you click on the line you added.
  3. Continue holding down the Shift key as you click the chart. (Best place is to click the border of the chart.)
  4. Release the Shift key. All three elements remain selected.
  5. Display the Format tab of the ribbon.
  6. In the Arrange group, click the Group tool and then choose the Group option.

At this point, all three items are grouped together and they move as a whole. You'll note that, after grouping, there is an "outer" border on the group that is a bit outside the original chart border. It is this outer border you'll need to click to select the group as you move it around.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (736) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021.

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

Shifting Objects Off a Sheet

One day you are just editing your worksheet like you normally do, then you see an error that says "Cannot shift object ...

Discover More

Testing if a Workbook is Open

Your macros can easily open and manipulate other Excel workbooks. If a workbook you are trying to use is already in use ...

Discover More

Easily Finding Superscripts

Word has a powerful Find and Replace capability, but sometimes it can be tricky to figure out exactly how to use it. Here ...

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 (ribbon)

Automatically Creating Charts for Individual Rows in a Data Table

If you have a lot of records in a data table, you may want to create individual charts based on the information in those ...

Discover More

Adding Data Labels to Your Chart

Adding labels to a chart can make the information presented in the chart more understandable. Excel allows you to add ...

Discover More

Creating a Year-to-Date Comparison Chart

Excel is an excellent tool for keeping track of data over time. If you have information you are keeping by year, you may ...

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 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.

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.