All function
Syntax
All(fieldlist)
Where fieldlist is an arbitrary-length list of field names in the form:
[recordname.]fieldname1 [, [recordname.]fieldname2] ...
Description
Use the All function to verify if a field contains a value, or if all the fields in a list of fields contain values. If any of the fields are Null, then All returns False.
A blank character field, or a zero (0) numeric value in a required numeric field is considered a null value.
Returns
Returns a Boolean value based on the values in fieldlist. The All function returns True if all of the specified fields have a value; it returns False if any one of the fields does not contain a value.
Example
The All function is commonly used in SaveEdit PeopleCode to ensure that a group of related fields are all entered. For example:
If All(RETURN_DT, BEGIN_DT) and
8 * (RETURN_DT - BEGIN_DT) (DURATION_DAYS * 8 + DURATION_HOURS)
Then
Warning MsgGet(1000, 1, "Duration of absence exceeds standard hours for number⇒
of days absent.");
End-if;
Related Functions
| Function | Description |
|---|---|
|
Checks if either all the field parameters have values, or none of them have values. Use this in examples where if the user fills in one field, she must fill in all the other related values. |
|
|
Checks that a field or list of fields have no value. |
|
|
Checks if exactly one field in the set has a value. Use this when the user must fill in only one of a set of mutually exclusive fields. |
|
|
Checks if no more than one field in the set has a value. Use this in examples when a set of fields is both optional and mutually exclusive; that is, if the user can put a value into one field in a set of fields, or leave them all empty. |
Related Topics