References: Putting It Together
About this lesson
Relative references move when a formula is copied. Absolute references never move. Mixed references move in one direction only. Most real formulas use more than one kind.
- choose relative, absolute or mixed for every reference in a formula.
- build a costing sheet where changing one rate updates every figure.
The idea
Everything in this module on one sheet. The rule is the same every time: when I copy this formula, should this reference move? Row data moves. Facts that apply to the whole sheet do not. Anything that fills a block in two directions needs a mixed reference.
Here is where the effort pays. A locked rate is not just neat. It is what lets the sheet answer a question. Change the session length in one cell, and every hours figure and every cost moves with it at once. You can see the new number before you commit to it. A sheet with the rate typed into forty formulas cannot do that. It looks the same until the day somebody asks.
The mistake to watch for
A half-locked reference like B$7 can be correct where it was written and wrong where it is copied. It holds in one direction only. Before you fill, decide which way the formula will travel. A lock that is right for filling down is not enough for filling across.
Read more about this
Where this comes up again
This lesson needs JavaScript to run. Everything below is the lesson in full, but you cannot type into the grid or be marked.
B6 holds the session length. It stays locked, so it never moves.
In D2, type:
=C2*$B$6
That is sessions times session length.
| Row | A | B | C | D | E | F | G |
|---|---|---|---|---|---|---|---|
| 1 | Class | Learners | Sessions | Hours | Cost | ||
| 2 | Beginners | 14 | 8 | ||||
| 3 | Improvers | 9 | 12 | ||||
| 4 | Advanced | 6 | 12 | ||||
| 5 | |||||||
| 6 | Hours per session | 1.5 | |||||
| 7 | Cost per hour | 46 | |||||
| 8 |
Every step
-
B6holds the session length. It stays locked, so it never moves. InD2, type:=C2*$B$6. That is sessions times session length. -
In
E2, multiplyD2by the locked rate inB7. That is hours times cost per hour. -
E3was filled fromE2, but its rate now points atB8, which is empty. FixE3. -
In
E6, totalE2:E4withSUM. -
B6is still 1.5. It changes after this step. Read=C3*$B$6and say what it returns. -
Locking only the row still lets the column move. Read
=D4*B$7and say what it returns inE4.