Microsoft Office Tutorials and References
In Depth Information
Adding a Column of Numbers
Let’s take note of what we’re looking at. Clicking the AutoSum button in H8 installs the
expression shown in Figure 4–3. This expression uses Excel’s built-in
And what is that expression telling us? It’s telling us that Excel plans to add all the
values in the range H3:H7. Press Enter and you’ll see the result, 267, in cell H8. Voila!
This expression is called a formula (you can tell a formula because it starts with an equal
sign (=), and this formula displays the result of the
function. You can read the
formula as “The contents of this cell equal the result of the
function.” In the
“Customizing the Worksheet with Formulas” section later in this chapter, I will teach you
how to write formulas from scratch. For now we are going to use the built-in functions,
which make writing formulas quick and easy (and it’s the functions that we really care
about, because they do the hard work for us).
NOTE: If you double-click the AutoSum button, it will display its result immediately in its cell,
without stopping to reveal its formula as in Figure 4–3.
Now type in cell H4, replacing the original 67. Cell H8 will now show 271. This 71
demonstrates what’s perhaps the single greatest contribution of spreadsheets to
Western civilization: automatic recalculation. Once a formula has been placed on a
worksheet, any change in the values used in the formula will immediately change the
formula’s result. There’s no need to rewrite the formula—it delivers the new result
automatically. Just change the contributing values, and the answer changes.
Returning to our example, we see that it works because
is programmed to add all
the values in the cells directly above it (or to its left, if you’re adding values in a row); that
is, it adds the cells that actually contain a value. And that means that if we had
encountered this range shown in Figure 4–4 in H3:H7 instead, and had clicked AutoSum
again in H8, we’d have seen the result shown in Figure 4–5.
Figure 4–4. Something’s missing: Adding (or trying to add) the values in this range