<< 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 helper for applying named ranges: It scans all formulas in the selected area. 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 you want to apply. Alternatively, click Select all to select all names. |
4. | Confirm with OK. |
PlanMaker now searches all cell references within the selected area. 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). Using the ribbon command Formula | group Named range | Apply names, the formula in this cell will be converted to =SUM(January).
The option "Also apply to relative references"
In the dialog box mentioned above, you will find an option named Also apply to relative references. This option should remain enabled in most cases.
This option means the following:
In PlanMaker, names always refer to cell ranges with absolute addressing (like $A$1:$A$10). But in most calculations, the relative addressing is commonly used (like A1:A10).
If this option is enabled, PlanMaker will convert relative cell references as well.
If it is not disabled, PlanMaker will only convert absolute cell references.
An example:
Assume 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). But if you apply it to the formula =SUM(A1:A10), the formula will be converted only if the option Also apply to relative references is enabled.
For more information on absolute and relative cell addresses, see Relative versus absolute cell references.