Sunteți pe pagina 1din 20

Excel Formulas Review

About Formulas and Errors


About Formulas
Errors

Writing Excel Formulas


Simple Formulas
Formulas that use Cell or Range Name References
Formulas that Contain a Function
Formulas with Links to Other Worksheets & Workbooks

Examples of Common Formulas


Add Dates
Financial
Mathematical

About formulas
Formulas are equations that perform calculations on values in your worksheet.
A formula starts with an equal sign (=). For example, the following formula
multiplies 2 by 3 and then adds 5 to the result.

=5+2*3
A formula can also contain any or all of the following: functions,
references, operators, and constants.

Parts of a formula:

1 Functions: The PI() function returns the value of pi: 3.142...


2 References (or names): A2 returns the value in cell A2.
3 Constants: Numbers or text values entered directly into a formula, such as 2.
4 Operators: The ^ (caret) operator raises a number to a power, and the * (asterisk) operator multiplies.

ur worksheet.
ng formula

sterisk) operator multiplies.

A Simple Excel Formula

Example formula

What it does

=128+345

Adds 128 and 345

=5^2

Squares 5

1. Click the cell in which you want to enter the formula.


2. Type = (an equal sign).
3. Enter the formula.
4. Press ENTER.

A Formula that Contains References or Names


The following formulas contain relative references to and names of other cells.
The cell that contains the formula is known as a dependent cell when its value
depends on the values in other cells. For example, cell B2 is a dependent cell
if it contains the formula =C2.
Example formula

What it does

=C2

Uses the value in the cell C2

=Sheet2!B2

Uses the value in cell B2 on Sheet2

=Asset-Liability

Subtracts a cell named Liability from a cell


named Asset

Notes:
1. Click the cell in which you want to enter the formula.
2. In the formula bar type = (equal sign).
3. Do one of the following:
To create a reference, select a cell, a range of cells, a location
in another worksheet, or a location in another workbook. You can
drag the border of the cell selection to move the selection, or drag
the corner of the border to expand the selection.
To create a reference to a named range, press F3,
select the name in the Paste name box, and click OK.
4. Press ENTER.

s of other cells.
when its value
dependent cell

A Formula that Contains a Function


The following formulas contain functions.
Example formula

What it does

=SUM(A:A)

Adds all numbers in column A

=AVERAGE(A1:B4)

Averages all numbers in the range

Notes
1. Click the cell in which you want to enter the formula.
2. To start the formula with the function, click Insert Function
on the formula bar.
3. Select the function you want to use. You can enter a question
that describes what you want to do in the Search for a function box
(for example, "add numbers" returns the SUM function),
or browse from the categories in the Or Select a category box.
4. Enter the arguments. To enter cell references as an argument,
click Collapse Dialog to temporarily hide the dialog box.
Select the cells on the worksheet, then press Expand Dialog
5. When you complete the formula, press ENTER.

Formulas with Links


These formulas contain links to cells in the worksheet named "LinkedTo":
Example formula
=LinkedTo!C9* 1.1
=SUM(LinkedTo!C12:D12)

What it does
Increases the Widget A January Production
Level (2,500) by 10%.
Sums January and February production
totals for all Widget types.

Links can also be made to cells in other workbooks. For example, to write a formula
with a reference to Cell A1 in the worksheet named "OtherSheet" that's located
in the workbook named "OtherBook", the reference would look like this:
=[OtherBook.xls]OtherSheet!$A$1+ 100

Formula Result

to write a formula
that's located

2,750
16,439

A "Linked-To" Worksheet
That is, formulas on another sheet reference cells on this sheet.
See the worksheet named "With Links" for details.
Projected Production Levels
Jan

Feb

Mar

Totals:

Widget B

2,500
1,100

3,250
980

4,260
1,289

10,010
3,369

Widget C

4,320

4,289

4,090

12,699

7,920

8,519

9,639

26,078

Widget A

Totals:

Add Dates

Date

Days to add

6/9/2007

6/9/2016

12/10/2008

54

Formula

Description (Result)

=B6+C6

Add 3 days to 6/9/2007 (6/12/2007)

=B7+C7

Add 5 days to the current day (varies)

=B8+C8

Add 54 days to 12/10/2008 (2/2/2009)

Running Balance
Formulas

Deposits

Withdrawals

Balance

$1,000

$625

$375

=SUM(A2,-B2)

1000

740

$635

=SUM(C2,A3,-B3)

Formulas for the first two rows of a running balance column.

Common Financial: Create a Running Balance

Salesperson

Invoice

Buchanan
Buchanan
Suyama
Suyama
Buchanan
Dodsworth

15,000
9,000
8,000
20,000
5,000
22,500

Formula

Description (Result)

Sample Data

=SUM(B2:B3, B5)

Adds 2 invoices from Buchanan, and one


from Suyama (44,000)

=SUM(B2,B5,B7)

Adds individual invoices from Buchanan,


Suyama, and Dodsworth (57,500)

=SUM(Invoices)

Adds the values in the range named invoices:


B2:B7.

=SUM(B2:B7)

Sum all invoices.

Formulas using the Sample Data

Common Mathematical: Add Numbers

S-ar putea să vă placă și