Free cookie consent management tool by TermsFeed Validation Message
Validation Message

Validation Message

Function: a!validationMessage()

Configures a validation message for forms, sections, and editable grids.

See also: Form, Section, Editable Grid

Parameters

Name Keyword Type Description
Message message Text The validation message to display
Validate After validateAfter Text Determines when to display the validation message. Valid values are REFRESH (default), and SUBMIT.
Visibility showWhen Boolean Determines whether the validation is displayed on the interface. When set to false, the validation is hidden and is not evaluated. Default: true.

Notes

  • Only supported in form, section, and editable grid components.
  • When Validate After is "SUBMIT", the validation message is only displayed when the user selects a button component where validate is true, or when the user selects a submit button.

Examples

Copy and paste an example into the INTERFACE DEFINITION in EXPRESSION MODE to see it displayed.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
=a!localVariables(
  local!amount: 5000,
  a!formLayout(
    contents: {
      a!textField(
        label: "Amount",
        value: local!amount,
        saveInto: local!amount
      )
    },
    buttons: {
      a!buttonArrayLayout(
        buttons: {
          a!buttonWidget(
            label: "Submit",
            style: "PRIMARY",
            submit: true
          )
        }
      )
    },
    validations: a!validationMessage(
      message: "The total cannot be greater than $1,000",
      validateAfter: "REFRESH",
      showWhen: local!amount > 1000
    )
  )
)

Validation Message

FEEDBACK