Excel for Microsoft 365 Excel for the web Excel 2021 Excel 2019 Excel 2016 Excel 2013 Excel 2010 More…Less
When you create a simple formula or a formula by that uses a function, you can refer to data in worksheet cells by including cell references in the formula arguments. For example, when you enter or select the cell reference A2, the formula uses the value of that cell to calculate the result. You can also reference a range of cells.
For more information about cell references, see Create or change a cell reference. For more information about formulas in general, see Overview of formulas.
-
Click the cell in which you want to enter the formula.
-
In the formula bar , type = (equal sign).
-
Do one of the following, select the cell that contains the value you want or type its cell reference.
You can refer to a single cell, a range of cells, a location in another worksheet, or a location in another workbook.
When selecting a range of cells, you can drag the border of the cell selection to move the selection, or drag the corner of the border to expand the selection.
1. The first cell reference is B3, the color is blue, and the cell range has a blue border with square corners.
2. The second cell reference is C3, the color is green, and the cell range has a green border with square corners.
Note: If there is no square corner on a color-coded border, the reference is to a named range.
-
Press Enter.
Example
Copy the example data in the following table, and paste it in cell A1 of a new Excel worksheet. For formulas to show results, select them, press F2, and then press Enter. If you need to, you can adjust the column widths to see all the data. Use the Define Name command (Formulas tab, Defined Names group) to define «Assets» (B2:B4) and «Liabilities» (C2:C4).
Department |
Assets |
Liabilities |
IT |
274000 |
71000 |
Admin |
67000 |
18000 |
HR |
44000 |
3000 |
Formula |
Description |
Result |
‘=SUM(Assets) |
Returns the total of the assets for the three departments in defined name «Assets,» which is defined as the cell range B2:B4. (385000) |
=SUM(Assets) |
‘=SUM(Assets)-SUM(Liabilities) |
Subtracts the sum of the defined name «Liabilities» from the sum of the defined name «Assets.» (293000) |
=SUM(Assets)-SUM(Liabilities) |
Top of Page
Need more help?
Want more options?
Explore subscription benefits, browse training courses, learn how to secure your device, and more.
Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.
Hi Guys,
As you delve deeper into excel formulas you have to be insanely good at some ‘bird’ called Cell Referencing. If you have not heard of it.. that’s okay, heard of it but not know much .. that is also okay. Let’s go and unravel this concept..
Cell Referencing – What is it ?
To put it in simple words, when you refer to any cell (for example =A1) it is called cell referencing. Well, nothing great about it, agree! but let’s explore this a bit further. So I have a case where I am adding Salary and Commission to get Total Compensation
Take a note of few things above
- I make the formula in the first cell and I drag it down to the rest of the cells
- Excel automatically understands that it has to pick up cells in the next row to get the next total
- The cell references change automatically ! (from B3+C3 in first row to B10+C10 in last row)
Absolute Cell Referencing
When the cell references don’t move at all it is an absolute cell reference. Take a look at a slightly different case, we are supposed to calculate a 10% commission for all
Take a note of
- The commission % cell (D2) does not move down as I copy the formula down
- I apply $ sign to freeze ($D$2) by pressing the F4 key once (my cursor being on D2 in the formula)
- An alternative to absolute referencing is Cell Naming
Mixed Referencing
Sometimes or rather most often the need is a bit more tricky. Take a look, we need to calculate the total salaries of Senior to Junior Management which is equal to Salaries + Allowances (month wise) + Perks (level wise). Now we have to make one formula and copy it across the cells
Take a note of
- Allowances column is fixed so I am freezing only the column by pressing F4 three times ($C9)
- Salaries are different (for all employees) and are spread in columns and rows so we don’t freeze anything here (E9)
- Perks are kept in row 5 but, so only freeze the row here by pressing F4 two times, (E$5)
Time for Some Tricks 😀
RUNNING TOTALS– Consider this example where we have to total the sales as we proceed in months (running total)
The trick is to freeze the only start of the range i.e. $C$5 (pressing F4 once) and we are sorted !
EXPANDING RANGES IN VLOOKUP
So here we have Months, Sales and Region and we want to lookup for 3 months sales and region in the look up table
Note a few interesting things
- I am freezing the month column ($F6) because when I copy the formula to the right, I still want to look up based on month
- I am just selecting the month and sales in table_array input, as I copy the formula right the range expands because I have done absolute referencing to the start of the range ($B$6) and only freezing the row number (C$17) at the end of the array
- The row numbers don’t change (G$4) for column index number in VLOOKUP, so a mixed referencing (2 times F4, for locking only the row)
- Learn VLOOKUP + some additional VLOOKUP tricks
Closing thoughts
- Most often people refer to cell referencing as locking the cell, which is entirely not correct but kind of understood in the same way by everyone, so that is fine. They’ll say like … hey man, lock the row in your formula, or lock the column and the formula would work 😀
- Remember for locking ( 😀 ), I mean applying the $ sign
- The entire cell (row and column) Press F4 once
- Only the row, press F4 twice
- Only the column, press F4 thrice
- Unlock, press F4 four times
- Now cell referencing is just not limited to formulas, it becomes a beast in cell naming and formula driven condition formatting (we’ll spare that for some other day)
Download the file here from down below. Please tell me how do you use cell referencing ?
Topics that I write about…
goodly
Cell referencing in Excel is an indispensable knowledge when mastering Microsoft Excel. It is the process of representing the value of a cell in another cell within a workbook.
Cell references in Excel are a simple way of letting another cell know the value of a cell by using cell addresses. As discussed before, a cell address is represented by the intersection of a column label and a row number.
For example, the image below shows a worksheet with different cell references for computing students’ total and average scores.
In the worksheet above, you can observe that in cell references, you can link to a cell or range. Linking to a cell, e.g., =B1 is the simplest form of a cell reference. In this tutorial, we shall discuss in detail cell referencing in Excel.
Cell Reference in Excel
What is a cell reference?
A cell reference is the value of a cell or range of cells represented in another cell within a worksheet. The cell reference usually represents the address of the referred cell or range in the current cell.
Because cell referencing copies the value of a cell to another, it is usually used in Excel formulas. They represent a variable in Excel formulas because the result of the formula changes when the value of such cells changes.
When working with cell referencing in Excel, you can reference cells as follow:
- Cells within the same worksheet in a workbook
- Cells in a different worksheet in the same workbook, and
- Cells in a worksheet in a different workbook
When cell reference is used in formulas, it helps Excel to locate the actual data or value of such cell. Valid data or values are therefore used by the formula to perform the necessary computations.
Types of cell reference in excel
There are three (3) main types of cell reference in Excel, namely
- Absolute cell reference
- Relative cell reference, and
- Mixed cell reference
There are two (2) other types that are not often used. However, you may find yourself using them in some cases. They are:
- Circular cell reference, and
- 3-D cell reference
Let us discuss each of these types of cell references with examples.
Absolute cell referencing in excel
An absolute cell reference is used to represent a constant cell in Microsoft Excel. When working with formulas in Excel, we usually copy and fill formulas into other rows and columns. This helps to save the time it will take to type the same formula in different cells.
In Microsoft Excel, when formulas are copied, the cell address changes relative to the position of the column/row. This means that, if you copy a formula from cell B2 to cell B3, the reference changes to reflect B3 by default.
However, in absolute cell referencing, this does not happen. The cell address being copied remains constant across the cells it was copied.
To achieve absolute cell referencing in Excel, you must add a dollar sign ($) in the cell address. For example, instead of B2, we have $B$2. This will ensure that cell B2 remains constant when it is copied.
Let us illustrate;
In the diagram below, if we copy the formula in H2 through H11, the result will be the same as shown.
What this means is that the value of cell H2 is replicated all through the cells it is copied to. If the value of cell H2 changes, the result in the referenced cells also changes to reflect the change.
There are cases when you will use absolute cell referencing in computations. For example, if you are working on a variable that has a fixed value, e.g. VAT, interest rate, rent, etc.
Since the value will remain the same in all computations, it is better to make it constant. If the value changes, it reflects in all computations.
Relative cell referencing in excel
Microsoft Excel uses relative cell reference by default. Relative cell referencing is the process of referencing a corresponding cell based on the relative position of a column/row.
This means that when you copy a formula in cell H2 to cell H3, the cell reference changes to H3. That is, the formula will now refer to the corresponding cells in relation to cell H3.
This type of cell reference makes working with excel formulas easy and less tedious. Using this type of cell reference, you can copy a single formula to multiple columns/rows and worksheets.
To use absolute cell referencing, use cell addresses and ranges as they appear by default. That is, use cell A1 as A1 in a referenced cell.
For example, the diagram below shows that copying the formula in I2 through I11 will vary the result.
The result of cells I2 through I11 will vary depending on the corresponding values of cells in their relative positions. E.g., the value of I5 is the sum of cells C5, D5, E5, F5, and G5.
The table below shows how relative cell reference works when the autofill handle is dragged downwards.
Mixed cell referencing in excel
A mixed cell referencing is a process of keeping the row constant while varying the column and vice versa.
By default, when a formula is copied down a column, that column becomes constant. Similarly, when copying within the same row, that row becomes constant.
However, when formulas and functions are copied between rows and columns, you may need to keep either row or column constant.
A mixed cell reference uses the dollar sign ($) on either the column label or the row number. For instance,
Mixed Cell Reference | Description |
A$1 | The column is relative while the row is absolute. When copied across columns and rows, values change to reflect the corresponding column position, while rows remain the same. |
$A1 | The row is relative while the column is absolute. When copied across columns and rows values change to reflect the corresponding row position, while columns remain the same. |
In the example below, we are calculating three (3) different prices of a product based on 3 markups. The price markups appear in row 20 and columns C, D, and E as shown in the worksheet below.
To get the three price levels for each product, we make the row absolute and make the column relative. And to get the price level of all the products, we make the column absolute and row relative.
Hence, we enter the following formula in cell D21 [=(1 + C$20)*$C23]. When you drag across columns, you’ll get price 2 and price 3. When you drag across rows, you get prices for each product at each price level as shown below.
In the worksheet above, we added the dollar sign (C$20) before the row number to make the row fixed. So, when the formula is copied across the rows, the referenced row remains constant and will not change. Similarly, we added the dollar sign ($C23) before the column label to make the column fixed. So, when the formula is copied across the columns, the referenced column remains constant and will not change.
Tip: switch between cell references
You can easily switch between the three types of cell references without typing a dollar sign. To switch between relative to absolute and to mixed cell references, do the following.
- Select the cell that contains the cell reference that you want to change, e.g., C2
- As the cell is selected, click on the formula bar to activate cell editing
- With cell editing active, press F4 on the keyboard.
- Continue pressing F4 until you get your desired cell reference type.
Circular cell referencing in excel
A circular cell reference is a cell that refers to itself directly or indirectly. Microsoft Excel will usually warn you when you use a circular cell reference, hence it’s not to be advised.
However, there are cases when you may use it. For example, in the worksheet above, I entered formula to calculate the cost rate and the cost of a product. The formula is as follow:
- In cell E2 we have [=F2/D2], to get the product cost rate, and
- In cell F2 we have [=D2*E2], to get the total product cost
This is a case of a cell referencing itself indirectly because one value results in another. However, this kind of circular reference is removed when the value of one cell is entered.
3-d cell referencing in excel
A 3-d cell reference in excel is used to reference more than one worksheet at the same time. The worksheets to be referenced usually have the same structure.
For example, the worksheet below calculates the total, average, max, and min scores of students in JS1A, JS1B, and JS1C.
The worksheets have the same structure and occupy sheet names: JS1A, JS1B, and JS1C. We want to calculate the summary scores for the 3 classes at the same time in a worksheet. To perform the calculations, we enter the following formulas:
English | Maths | Agric. | Science | Social | |
Total score | =SUM(JS1A:JS1C!C2:C16) | ||||
Average score | =AVERAGE(JS1A:JS1C!C2:C16) | ||||
Max score | =MAX(JS1A:JS1C!C2:C16) | ||||
Min score | =MIN(JS1A:JS1C!C2:C15) |
The above formula can be easily entered in the required cells as follow:
- Select the cell where you want to place the calculation, e.g., B2
- Enter the required function, e.g., =SUM(
- Select the first sheet tab in the 3d reference, in this case, sheet JS1A
- Hold the SHIFT key on the keyboard and click the last sheet tab in the 3d reference, JS1C
- Select the data range for the calculation, in this case, C2:C16
- Close the bracket and press ENTER on the keyboard.
Reference cell in excel
As highlighted above, you can reference a cell within the same worksheet, in a different worksheet and workbook. In this section, we shall look at how to create cell references in excel.
Reference a cell on the same worksheet
The examples we have given so far show how to reference a cell on the same worksheet. This can be achieved by referencing a single cell, range, or defined name as shown below.
Cell Reference | Explanation |
=C2 | This is a simple reference that refers to C2 and will return the value of C2 in the selected cell |
=D2:D11 | This is a range reference that refers to cells D2 through D11. It will return the values of all the cells in the selected range. |
=Eng | This is a named reference that refers to a cell or range named ‘Eng’ and will return the value(s) contained in Eng. |
How to create cell reference on the same worksheet
- Select the cell in which you want to enter the cell reference.
- Type the equal sign (=) on the formula bar. You can also enter the formula you want.
- Select a cell or range of cells on the same worksheet.
- If you selected a cell, press Enter key on the keyboard. If you selected a range of cells, hold CTRL+SHIFT and press the ENTER key on the keyboard. You can also close the formula bracket if you entered a formula, and press ENTER on the keyboard.
- If you are referencing a defined name,
- Type in the defined cell or range name, and press ENTER, or
- Press F3 and select the defined name from the Paste Name dialog box, click OK, and press ENTER.
Reference a cell to another worksheet
When working with multiple worksheets on the same workbook, you can create cell references between worksheets. The difference between this and the previous is that you will add the sheet name with an exclamation mark (!).
This can be achieved by referencing a single cell, or range as shown below.
Cell Reference | Explanation |
=Sheet1!C2 | This is a simple cross-reference that refers to Sheet1 and cell C2 and will return the value of C2 in the selected cell |
=Sheet1!D2:D11 | This is a range cross-reference that refers to Sheet1 and cells D2 through D11. It will return the values of all the cells in the selected range. |
Defined name | Defined names are unique in a workbook. You can refer to a defined name from any worksheet in the same workbook. |
How to create cell reference to another worksheet
- Select the cell in which you want to enter the cell reference.
- Type the equal sign (=) on the formula bar. You can also enter the formula you want.
- Select the sheet tab of the worksheet you want to enter its cell reference.
- Select a cell or range of cells in the selected worksheet in (3) above.
- If you selected a cell, press Enter key on the keyboard.
- If you selected a range of cells, hold CTRL+SHIFT and press the ENTER key on the keyboard. You can also close the formula bracket if you entered a formula, and press ENTER on the keyboard.
Create cell reference to another workbook
You can also link to a cell, range, or defined name in another workbook. When data in the referenced workbook changes, it updates in the referring workbook as well.
Here, you will enclose the workbook name in a square bracket followed by the sheet name, and the cell. This can be achieved by referencing a single cell or range as shown below.
Cell Reference | Explanation |
='[workbook name.xlsx]Sheet1′!$G$2 | Referring to a cell in sheet1 of another workbook |
='[workbook name.xlsx]Sheet1′!$C$4:$G$4 | Referring to a range in sheet1 of another workbook |
=’workbook name.xlsx’!definedname | Referring to a defined name in another workbook |
How to create cell reference to another workbook
- Open both workbooks, if more than two, open all the workbooks.
- Select the cell in which you want to enter the cell reference.
- Type the equal sign (=) on the formula bar. You can also enter the formula you want.
- Select the workbook you want to enter its cell reference.
- Select the sheet tab of the worksheet you want to enter its cell reference
- If you selected a cell, press Enter key on the keyboard.
- If you selected a range of cells, hold CTRL+SHIFT and press the ENTER key on the keyboard. You can also close the formula bracket if you entered a formula, and press ENTER on the keyboard.
- If you are referencing a defined name,
- Type in the defined cell or range name, and press ENTER, or
- Press F3 and select the defined name from the Paste Name dialog box, click OK, and press ENTER.
Conclusion
Cell referencing in Excel is very important. Its knowledge will help you master how to add and copy formulas in Excel to make your work easy.
So far, we have discussed what is cell a cell reference, and the types of cell referencing in Excel. We also discussed how to create cell references in a workbook.
If you did not understand any part of this tutorial, please, contact us for clarification. We shall continue next week with working with formulas in Excel. Before then, kindly click the share button to share.
Previous tutorials in this series include:
- What is Microsoft Excel: Tutorial 1
- Entering and formatting data in Excel: Tutorial 2
- Conditional formatting in Excel: Uses and Applications
- Formatting Numbers and Worksheet in Excel
A worksheet in Excel is made up of cells. These cells can be referenced by specifying the row value and the column value.
For example, A1 would refer to the first row (specified as 1) and the first column (specified as A). Similarly, B3 would be the third row and second column.
The power of Excel lies in the fact that you can use these cell references in other cells when creating formulas.
Now there are three kinds of cell references that you can use in Excel:
- Relative Cell References
- Absolute Cell References
- Mixed Cell References
Understanding these different types of cell references will help you work with formulas and save time (especially when copy-pasting formulas).
What are Relative Cell References in Excel?
Let me take a simple example to explain the concept of relative cell references in Excel.
Suppose I have a data set shown below:
To calculate the total for each item, we need to multiply the price of each item with the quantity of that item.
For the first item, the formula in cell D2 would be B2* C2 (as shown below):
Now, instead of entering the formula for all the cells one by one, you can simply copy cell D2 and paste it into all the other cells (D3:D8). When you do it, you will notice that the cell reference automatically adjusts to refer to the corresponding row. For example, the formula in cell D3 becomes B3*C3 and the formula in D4 becomes B4*C4.
These cell references that adjust itself when the cell is copied are called relative cell references in Excel.
When to Use Relative Cell References in Excel?
Relative cell references are useful when you have to create a formula for a range of cells and the formula needs to refer to a relative cell reference.
In such cases, you can create the formula for one cell and copy-paste it into all cells.
What are Absolute Cell References in Excel?
Unlike relative cell references, absolute cell references don’t change when you copy the formula to other cells.
For example, suppose you have the data set as shown below where you have to calculate the commission for each item’s total sales.
The commission is 20% and is listed in cell G1.
To get the commission amount for each item sale, use the following formula in cell E2 and copy for all cells:
=D2*$G$1
Note that there are two dollar signs ($) in the cell reference that has the commission – $G$2.
What does the Dollar ($) sign do?
A dollar symbol, when added in front of the row and column number, makes it absolute (i.e., stops the row and column number from changing when copied to other cells).
For example, in the above case, when I copy the formula from cell E2 to E3, it changes from =D2*$G$1 to =D3*$G$1.
Note that while D2 changes to D3, $G$1 doesn’t change.
Since we have added a dollar symbol in front of ‘G’ and ‘1’ in G1, it wouldn’t let the cell reference change when it’s copied.
Hence this makes the cell reference absolute.
When to Use Absolute Cell References in Excel?
Absolute cell references are useful when you don’t want the cell reference to change as you copy formulas. This could be the case when you have a fixed value that you need to use in the formula (such as tax rate, commission rate, number of months, etc.)
While you can also hard code this value in the formula (i.e., use 20% instead of $G$2), having it in a cell and then using the cell reference allows you to change it at a future date.
For example, if your commission structure changes and you’re now paying out 25% instead of 20%, you can simply change the value in cell G2, and all the formulas would automatically update.
What are Mixed Cell References in Excel?
Mixed cell references are a bit more tricky than the absolute and relative cell references.
There can be two types of mixed cell references:
- The row is locked while the column changes when the formula is copied.
- The column is locked while the row changes when the formula is copied.
Let’s see how it works using an example.
Below is a data set where you need to calculate the three tiers of commission based on the percentage value in cell E2, F2, and G2.
Now you can use the power of mixed reference to calculate all these commissions with just one formula.
Enter the below formula in cell E4 and copy for all cells.
=$B4*$C4*E$2
The above formula uses both kinds of mixed cell references (one where the row is locked and one where the column is locked).
Let’s analyze each cell reference and understand how it works:
- $B4 (and $C4) – In this reference, the dollar sign is right before the Column notation but not before the Row number. This means that when you copy the formula to the cells on the right, the reference will remain the same as the column is fixed. For example, if you copy the formula from E4 to F4, this reference would not change. However, when you copy it down, the row number would change as it is not locked.
- E$2 – In this reference, the dollar sign is right before the row number, and the Column notation has no dollar sign. This means that when you copy the formula down the cells, the reference will not change as the row number is locked. However, if you copy the formula to the right, the column alphabet would change as it’s not locked.
How to Change the Reference from Relative to Absolute (or Mixed)?
To change the reference from relative to absolute, you need to add the dollar sign before the column notation and the row number.
For example, A1 is a relative cell reference, and it would become absolute when you make it $A$1.
If you only have a couple of references to change, you may find it easy to change these references manually. So you can go to the formula bar and edit the formula (or select the cell, press F2, and then change it).
However, a faster way to do this is by using the keyboard shortcut – F4.
When you select a cell reference (in the formula bar or in the cell in edit mode) and press F4, it changes the reference.
Suppose you have the reference =A1 in a cell.
Here is what happens when you select the reference and press the F4 key.
- Press F4 key once: The cell reference changes from A1 to $A$1 (becomes ‘absolute’ from ‘relative’).
- Press F4 key two times: The cell reference changes from A1 to A$1 (changes to mixed reference where the row is locked).
- Press F4 key three times: The cell reference changes from A1 to $A1 (changes to mixed reference where the column is locked).
- Press F4 key four times: The cell reference becomes A1 again.
You May Also Like the Following Excel Tutorials:
- How to Copy and Paste Formulas in Excel without Changing Cell References
- How to Lock Cells in Excel.
- Excel Freeze Panes: Use it to Lock Row/Column Headers.
- How to Lock Formulas in Excel.
- How to Reference Another Sheet or Workbook in Excel
- How to Find Circular Reference in Excel
- Using A1 or R1C1 Reference Notation in Excel (& How to Change These)
In order to make accurate calculations in Excel, it’s essential to understand how the different types of cell references work.
A1 vs. R1C1 References
Excel worksheets contain many cells and (by default) each cell is identified by its column letter followed by its row number. This is known as A1-style referencing. Examples: A1, B4, C6
A1 reference style
Optionally, you can switch to R1C1 Reference Mode to refer to a cell’s row & column number. Instead of referring to cell A1 you would refer to R1C1 (row 1, column 1). Cell C4 would be referred to R4C3.
R1C1 reference style
R1C1-style referencing is extremely uncommon in Excel. Unless you have a good reason you should probably stick to the default A1-style reference mode. However, if you use VBA you will likely encounter this reference style.
Switch to R1C1 Reference Style
To switch the reference style, go to File > Option > Formula. Check the box next to R1C1 reference style.
Named Ranges
One of the most under-utilized features of Excel is the Named Ranges feature. Instead of referring to a cell (or group of cells) by its cell location (ex B3 or R3C2), you can name that range and simply reference the range name in your formulas.
To name a range:
- Select the cell or cells that you wish to name
- Click Inside the Range Name Box
- Enter your desired name
- Hit Enter
Now you can reference cell A1 by typing =range_name1 instead. This is very useful when working with large workbooks with multiple worksheets.
Range of Cells
When using Excel’s built in Functions, you may need to reference ranges of cells. Cell ranges appear like this ‘A1:B3’. This reference refers to all cells in between A1 and B3: cells A1,A2,A3, B1, B2, B3.
To select a range of cells when entering a formula:
- Type in the range (separate the start and end range with a semicolon)
- Use your mouse to click the first cell reference, hold down the mouse button and drag your desired range.
- Hold down the shift key and navigate with the arrow keys to select your range
Absolute (Frozen) and Relative References
When entering cell references within formulas, you can use relative or absolute (frozen) references. Relative references will move proportionally when you copy the formula to a new cell. Absolute references will remain unchanged. Let’s look at some examples:
Relative Reference
A relative reference in Excel looks like this
=A1
When you copy and paste a formula with relative references, the relative references will move proportionally. Unless you specify otherwise, your cell references will be relative (unfrozen) by default.
Example: If you copy ‘=A1’ down one row the reference changes to ‘=A2’.
Absolute (Frozen) Cell References
If you don’t want your cell references to move when you copy a formula, you can “freeze” your cell references by adding dollar signs ($s) in front of the reference that you want frozen. Now when you copy and paste the formula, the cell reference will remain unchanged. You can choose to freeze the row reference, column reference, or both.
A1: Nothing is frozen
$A1: The column is frozen, but the row is not frozen
A$1: The row is frozen, but the column is not frozen
$A$1: Both the row and column are frozen
Absolute Reference Shortcut
Manually adding in dollar signs ($s) into your formulas isn’t very practical. Instead, while creating your formula, use the F4 key to toggle between absolute/relative cell references.
Absolute Cell Reference Example
When would you actually need to freeze a cell reference? One common example is when you have input cells that are referenced frequently. In the example below, we want to calculate the sales tax for each quantity of menu items. The sales tax is constant across all items, so we will reference the sales tax cell repeatedly.
To find the total sales tax, enter the formula ‘=(B3*C3)*$C$1’ in column D and the copy the formula down.
Mixed Reference
You may have heard of mixed cell references. A mixed reference is when either the row or column reference is locked (but not both).
Mixed Reference
Remember, by using the “F4” key you are able to cycle through your relative, absolute cell references.
Cell References – Inserting & Deleting Rows/Columns
You may be wondering what happens to your cell references when you insert or delete rows/columns?
The cell reference will update automatically to refer to the original cell. This is the case regardless of whether the cell reference is frozen.
3D References
At times, you may need to work with several worksheets with identical patterns of data. Excel allows you to refer to multiple sheets at once without needing to manually enter each worksheet. You can reference a range of sheets similar to how would reference a range of cells. Example ‘Sheet1:Sheet5!A1’ would reference cells A1 on all sheets from Sheet1 to Sheet5.
Let’s walk through an example:
You want to add together the total units sold for each product across all stores. Each store has its own worksheet and all the worksheets have an identical format. You could create a formula similar to this:
This is not too difficult with only four worksheets, but what if you had 40 worksheets? Would you really want to manually add each cell reference?
Instead, you can use a 3D reference to reference multiple sheets at once with ease(similar to how you can reference a range of cells).
Be Careful! The order of your worksheets matters. If you move another sheet in between the referenced sheets (StoreA and StoreD) that sheet will be included. Conversely, if you move a sheet outside the range of sheets (before StoreA or after StoreD), it will no longer be included.
Circular Cell Reference
A circular cell reference is when a cell refers back to itself. For example, if the result of cell B1 is used as an input for cell B1 then a circular reference is created. The cell does not need to directly refer to itself There can be intermediate steps.
Example:
In this case, the formula for cell B2 is “A2+A3+B2”. Because you are in cell B2, you may not use B2 in the equation. This would trigger circular reference and the value in cell “B2” will automatically be set to “0”.
Usually circular references are a result of user error, but in there are circumstances in which you may want to use a circular reference. The primary example of using a circular reference is to calculate values iteratively. To do this, you need to go to File > Options > Formulas and Enabled Iterative Calculation:
External References
At times when calculating data you may need to refer to data outside of your workbook. This is called an external reference (link).
To select an external reference while creating a formula, navigate to the external workbook, and select your reference as you normally would.
To navigate to the other workbook you can use the CTRL + TAB shortcut or go to View > Switch Windows.
Once you’ve selected the cell, you’ll see that an external reference that looks like this:
Notice that the workbook name is enclosed by brackets [].
Once you close the referenced workbook, the reference will show the file location:
When you reopen the workbook containing the external link, you will be prompted to enable automatic updating of links. If you do so, then Excel will open the reference value with the current value of the workbook. Even if it’s closed! Be careful! You may or may not want this.
Named Ranges and External References
What happens to your external cell reference when rows / columns are added or deleted from the reference workbook? If both workbooks are open then the cell references update automatically. However, if both workbooks aren’t open then the cell references won’t update and will no longer be valid. This is a huge concern when linking to external workbooks. Many errors are caused by this.
If you do link to external workbooks, you should name the cell reference with a named range (see previous section for more information). Now your formula will refer to the named range no matter what changes occur on the external workbook.