April 24, 2010

IF Function

The IF function is one of Excel’s most useful and most used functions.

The function is used to see whether a certain condition is true or false.

The syntax of the IF function is =IF(logical test, value if true, value if false)
The IF function will check the logical condition of a statement and return one value if true and a different value if false.

Examples:

=IF(A2=15, "OK", "Not OK")
If the value in cell A2 equals 15, then return "OK".

=IF(A2<>9, "OK", "Not OK")
If the value in cell A2 is not equal to 9, then return "OK".

=IF(NOT(A2<=9), "OK", "Not OK")
If the value in cell A2 is not less than or equal to 9, then return "OK".

=IF(A5<>"Sharjah", "OK", "Not OK")
If the value in cell A5 is not equal to "Sharjah", then return "OK".

=IF(OR(A5 <>"Sharjah", A5<>"Dubai"), "OK", "Not OK")
If the value in cell A5 is not equal to "Sharjah" or "Dubai", then return "OK".

=IF(OR(A2<>A3, A2<>A4), "OK", "Not OK")
If A2 is not equal to A3 or A2 is not equal to A4, then return "OK".

The following videos provide an overview and examples of using the F Function:
Video 1:  IF function for simple lookups



Video 2: Using the IF Statement in Excel 2007


Video 3: IF function formula made easy!


Video 4: (Optional) IF function formula: 12 Examples! Part 1



Video 5: (Optional) IF function formula: 12 Examples! Part 2

No comments:

Post a Comment

Followers