FORMULA LANGUAGE


@For
Example

Executes one or more statements iteratively while a condition remains true. Executes an initialization statement. Checks the condition before executing the statements and executes an increment statement after executing the statements.

Note This @function is new with Release 6.

Syntax

@For( initialize ; condition ; increment ; statement ; ... )

Parameters

initialize


condition
increment
statement
Return value

true


Usage

@For executes the initialize statement once. Next @For evaluates the condition. If the condition is True (1), @For executes the statements, executes the increment statement, and evaluates the condition again. If the condition is False (0), @For terminates.

Tip If you are looping through a field containing a list, be sure the "Allow multiple values" check box is selected in the Field Properties box for the list field.

The formula engine exits a formula or breaks an infinite loop if the time spent performing the iterations exceeds the standard timeout value allowed for an operation.

For other iterative statements, see @DoWhile and @While.

Language cross-reference

While statement of LotusScript language

For statement of LotusScript language

Example
See Also