<< Click to Display Table of Contents >> IF (if-then-else condition) |
Syntax:
IF(Condition, IfTrue [, IfFalse])
Description:
This function returns IfTrue if the specified Condition is TRUE, otherwise it returns IfFalse (if given).
Condition can be any kind of value or expression that returns TRUE or FALSE.
IfTrue and IfFalse can be any kind of value or expression (including formulas).
Example:
The formula IF(A1<5, "Order!", "Stock ok") returns the text string "Order!" if A1<5. If this is not the case (A1 is thus ≥ 5), it returns the text string "Stock ok".
See also: