xpfIfThenElseIf

FUNCTION xpfIfThenElseIf (condition1  : LOGICAL; value1 : GENERIC;
                          condition2  : LOGICAL; value2 : GENERIC; 
                          condition3  : LOGICAL; value3 : GENERIC; 
                          condition4  : LOGICAL; value4 : GENERIC; 
                          condition5  : LOGICAL; value5 : GENERIC; 
                          condition6  : LOGICAL; value6 : GENERIC; 
                          condition7  : LOGICAL; value7 : GENERIC; 
                          condition8  : LOGICAL; value8 : GENERIC; 
                          condition9  : LOGICAL; value9 : GENERIC; 
                          condition10 : LOGICAL;value10 : GENERIC)
                          value                         : GENERIC;
                

Function to "emulate" an IF-THEN-ELSEIF statement. The function has variable number of arguments, i.e., it can be invoked with a minimum of 2 arguments and a maximum of 20 arguments and the number of arguments must be an even number.

This operation works as follows:

FOR each given condition argument DO
   IF (condition = TRUE) THEN
      RETURN(related value argument);
   END_IF;
END_FOR;
RETURN(?);

 

 

Arguments


1TypeNameComment
2LOGICALcondition1 - condition10A logical value. When the logical value has the value TRUE the related "value" argument will be returned from the xpfIfThenElseIf() operation
3GENERICvalue1 - value10Any legal value that will be returned from the xpfIfThenElseIf() operation when the related "condition" argument has the value TRUE.

Return Value


 

TypeNameComment
GENERICvalueThe function returns one of the "value" arguments or INDETERMINATE (?). Exception handling should be used to handle error conditions in the actual xpfIfThenElseIf() operation.

Options


 

Example


<Missing Example>

 

See also

Filter by label

There are no items with the selected labels at this time.

Â