...
Argument | Type | Description |
---|---|---|
$var | $-variable | A $-variable which will be set to each item in set in turn before script is processed. |
set | Array or Recordset | The set of items which will be iterated over. |
script | $-variable | A comma-separated list of expressions which will be processed once for each entry in set. |
forEach() is like every other function in that it returns a value.:
- Its return value is a list containing the last statement executed in each iteration.
- All the $-variables used in the call to forEach() keep their values between iterations.
- All the $-variables used in the call to forEach() will be available after it has returned.
...
Use in Conjunction With
Examples
In the first two examples, let
...