Evaluates a Boolean expression and returns one value if True (Then) and another if False (Else).
|
Syntax:
|
IF(Boolean, True Value, False Value)
|
Parameters:
|
Boolean: A Boolean expression that returns true or false.
|
Returns:
|
The second parameter True Value if the condition evaluates to True.
The third parameter False Value if the condition evaluates to False.
|
Example:
|
IF(A=1,Blue,Green)
The expression returns Blue if A=1 (True) and returns Green if A does not =1 (False)
|
Note:
|
You can also use a logical variable that returns True or False.
|
See also:
|
The Online and Rich Client Samples projects (program BS02 and RBS02)
|