# Tag Archives: What If Analysis The IF function evaluates a condition (a logical test), and then returns one value if the condition is true and another value if the condition is false.

Use the following information as a guideline for the IF Function.  It is also helpful to use the Function Arguments dialog box (shown above) to build the If Function.  (Click fx button to left of Formula Bar and Locate IF function.)

The IF function has three arguments:

A condition that is evaluated as true or false.

The value to be returned if the condition is true.

Value may be Text (surrounded by quotation marks; “” denotes leave blank)

Value may be a Number

Value may be a Formula

The value to be returned if the condition is false.

Value may be Text (surrounded by quotation marks; “” denotes leave blank)

Value may be a Number

Value may be a Formula

The condition (first argument) uses one of the following six relational operators:

 Equal To: = Not Equal To: <> Less Than: < Greater Than: > Less Than or Equal To: <= Greater Than or Equal To: >=

The format of the IF function is:

=IF(condition to be evaluated or logical test, value if true, value if false)

For example, if your employees were to receive a bonus or \$250 if their sales for the month of May were greater than or equal to \$1000, then here is what the IF function would look like in cell C8 for Ben (the first employee):

Ben’s sales for the month were \$1500 (B8) and the bonus cell is C8.

=IF(B8>=1000, 250, 0)  or to leave bonus cell blank  =IF(B8>=1000, 250, “”)

Condition to be evaluated: B8>=1000

Value if true:  250

Value if false:  0  (or “” to leave cell blank)

You could then copy the formula to determine which employees were to receive a bonus of \$250 and which employees were to receive no bonus.

If you have never used the IF function in Excel, give it a try.  The function is a real time saver when performing certain types of calculations using any version of Microsoft Excel.

______________________________________________________________________

For more information on the Business Office Systems and Support (BOSS) department, contact Becky Jones, Associate Dean, bjones@dcccd.edu 972-238-6215.