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: Applying Range Names to Formulas.

Applying Range Names to Formulas

by Allen Wyatt
(last updated October 26, 2013)

5

Named ranges can be a great boon when you are writing formulas. For instance, if you assign the name TaxRate to cell A7, you can then use the name TaxRate in your formulas instead of A7. This makes your formulas (and their purpose) easier to understand when you are later working with them.

This approach is great if you have not yet created any formulas. What if you already have a bunch of formulas in your worksheet, and they already reference cell A7 instead of TaxRate? You could, of course, select each formula and edit them to refer to TaxRate instead of A7, but that could be a long process that is prone to mistakes. (My fat fingers often introduce mistakes that I never intended. :>))

The solution is to allow Excel to do the editing for you. It is easy to do; just follow these steps:

  1. Define the named range you want used in your worksheet.
  2. Select the cells that contain formulas.
  3. Display the Formulas tab of the ribbon.
  4. Click the down-arrow at the right of the Define Name tool (in the Defined Names group) and then choose Apply Names. Excel displays the Apply Names dialog box. (See Figure 1.)
  5. Figure 1. The Apply Names dialog box.

  6. Click OK.

That's it; Excel examines your formulas and any reference to cell A7 is replaced with the name of A7, TaxRate.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (8266) applies to Microsoft Excel 2007, 2010, and 2013. You can find a version of this tip for the older menu interface of Excel here: Applying Range Names to Formulas.

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

Limiting Entries to Numeric Values

When creating a worksheet, you may need to limit what can be entered into a particular cell. Using data validation you can ...

Discover More

Controlling the View in Drive

Drive lets you organize and work with files that it stores for you. It also gives you control over how you view the files it ...

Discover More

Making Modal Dialog Boxes Appear in Front of Workbooks

Perhaps the most common way of communicating with programs is through the use of dialog boxes. We expect dialog boxes to be ...

Discover More

Professional Development Guidance! Four world-class developers offer start-to-finish guidance for building powerful, robust, and secure applications with Excel. The authors show how to consistently make the right design decisions and make the most of Excel's powerful features. Check out Professional Excel Development today!

More ExcelTips (ribbon)

Returning the Smallest Non-Zero Value

In a series of values you may need to know the smallest value that isn't a zero. There is no built-in function to do this, ...

Discover More

Counting Consecutive Negative Numbers

If you have a range of values that can be either positive or negative, you might wonder how to determine the largest ...

Discover More

Determining If a Value is Out of Limits

Need to figure out if a value is outside of some arbitrary limit related to a different value? There are a number of ways you ...

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}] in your comment text. You’ll be prompted to upload your image when you submit the comment. 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 three minus 2?

2015-10-31 14:21:53

mansour

in the this command has a VBA code.
my question is that :
in VBA Code , what is the "appendlast"?
please send your answer with comprehensive illustration.
thank you very much


2015-03-24 23:35:20

Matt

Having the same issue Gary mentioned, is there a solution to this problem. As he stated, much more likely to have range named cells on different sheets and the Apply Names function does not work in this situation.


2014-12-25 12:07:14

Nava

Gary, I recommend using the Find Replace function in lieu of the error you mention. Just tried it and that changed my cell references to Named Ranges. Looks like a bug in the latest 2013 version.


2014-01-16 20:26:49

Gary

This works if the formula is on the same worksheet as the defined names. What though if they are spread around on different sheets in the workbook? This is a much more likely scenario, but then Excel gives an error that Excel cannot find any references to replace.

Example: On Sheet 2, cell A1, type in the number 1. On Sheet 3, cell A1, type in the number 2. On sheet 1, enter the formula "=Sheet2!A1+Sheet3!A1"
The result is the expected value of 3.
Now define names for the cell A1 on sheet 2 and on sheet 3 cells (eg name them as ONE and as TWO). Now, apply these names and Excel fails to find any references to replace.

Is there any known solution to this problem??


2013-10-26 13:37:54

Juan

How great tip, really cool!


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.