<< Click to Display Table of Contents >> Applying names to existing formulas |
The ribbon command Apply names on the ribbon tab Formula | group Named areas is a useful option for using named ranges: It scans all formulas in the selected range. If it finds a cell reference within a formula for which a name has already been defined, it replaces it with the name.
You use this command as follows:
1. | Select the range of cells whose formulas you want to update. If you do not select anything, the entire worksheet will be affected. |
2. | Choose the ribbon command Formulas | group Named areas | Apply names . |
3. | In the Names list, select all names that you want to apply. Alternatively, click Select all to select all names. |
4. | Confirm with OK. |
PlanMaker now scans all cell references within the selected range. Any cell reference that has a name assigned to it will be replaced by the corresponding name.
An example:
The name "January" is assigned to cells A2 to A10. One of the cells in the worksheet contains the formula =SUM(A2:A10). If you now use the ribbon command Formula | group Named areas | Apply names, the formula in this cell will be converted to =SUM(January).
The option "Also apply to relative references"
The aforementioned dialog box contains the option Also apply to relative references. This option should normally remain enabled.
This option means the following:
In PlanMaker, names always refer to cell ranges with absolute addressing (like $A$1:$A$10). However, relative addressing is usually used in calculations (for example, A1:A10).
If this option is enabled, PlanMaker will also convert relative cell references.
If the option is disabled, PlanMaker will only convert absolute cell references.
An example:
Let's assume that the range from A1 to A10 (more precisely: $A$1:$A$10) was named "January". If you apply the Apply names function to the formula =SUM($A$1:$A$10), this formula will always be converted to =SUM(January). If you apply it to the formula =SUM(A1:A10), however, the formula will be converted only if the option Also apply to relative references is enabled.
For more information on this topic, see Relative versus absolute cell references.