Validator dialog box usage for fieldGroup

Is there any example regarding the use of built in Validator dialog boxes?
I cannot find examples or documentation regarding the use of “script reference” and “script text”.

Generic UI => fieldGroup => Properties => Fields => Validator =>
It has 3 fields: Class / Script reference / Script text.

Please see if there’s any example of the usage and syntax for these 3 fields.


Hi Jeremy,

We have one working example in Sampler, please take a look. If it remains unclear, let us know.

We did checked out the example on the sampler. However, it didn’t mention anything regarding the usage of “script reference” and “script text”. Wonder if there’s any example somewhere.

1 Like

Hi, below are the simplest examples of using validators:

  1. Script text
<field property="year">
        value ==~ /\d+/
  1. Script reference
<field property="zipCode">
    <validator script=""/>



return (value ==~ /\d+/)

Thank you for the question, it’s worth including in the documentation. We will do this.