Validation Rules for String Datatypes

Validation rules for STRING datatypes.

You can add multiple "contains" rules to the STRING datatype input on an Edit Box, but the rest of the validation rules can be assigned only once.

Before a string validation item is added to the control, these checks are performed to enforce the integrity of all the validations rules:
  • Each type of pattern match rule, except for the "contains" rule can be added only once to the Edit Box.
  • The “matches regular expression” rule supersedes other rules.
  • The “length is equal to” rule is mutually exclusive to “length is greater than,” “length is greater than or equal to,” “length is less than,” and “length is less than or equal to.”
  • The “length is greater than” rule is mutually exclusive to “length is greater than or equal to.”
  • If both “length is greater than” or “length is greater than” and “length is less than” or “length is less than or equal to” rules are added, a check on the range is also performed, and vice-versa.
  • The “length is less than” rule is mutually exclusive to “length is less than or equal to.”
Rule Description
contains Validates that the input contains the given string.
starts with Validates that the input starts with the given string.
ends with Validates that the input ends with the given string.
length is equal to Validates that the length of the input string is equal to the given length.
length is greater than Validates that the length of the input string is greater than the given length.
length is greater than or equal to Validates that the length of the input string is greater than or equal to the given length.
length is less than Validates that the length of the input string is less than the given length.
length is less than or equal to Validates that the length of the input string is less than or equal to the given length.
matches regular expression This rule supersedes other rules. Do not assign any other rules to the control. Validates that the input conforms to the given regular expression.