Documentation

Validating Text and Numeric Field Entries

Enable input validation to ensure that only certain values are accepted in a Text or Numeric field.

Enabling Field Validation

To enable validation:

  1. While viewing a form, click on a Text or Numeric field to open the field configuration menu.

  2. Click the Advanced tab.

  3. Switch the Validation toggle to the right to enable validation.

    Figure 1: Validate data to ensure you're collecting only useful information.

Once validation has been enabled, specify the If Input condition and enter the Show Error Message which indicate how validation failed.

Text Fields

See the Validation Conditions Reference for more information about the other validation conditions.

Validating Email Addresses

Forms can be configured to validate email addresses. To ensure that the user has entered a valid email address:

  1. Select the Is not email condition from the If Input dropdown.

  2. Enter the error message in the Show Error Message field: Please enter a valid email address.

  3. Click Save Form when finished.

    Use text field validation to make sure users enter a valid email address or URL.

Validating URLs

Similar to emails, Forms can be configured to validate URLs.

To validate URLs:

  1. Select the Is not URL condition from the If Input dropdown.

  2. Enter an error message.

  3. Click Save Form when finished.

Using Regular Expressions

Forms can be configured to use regular expressions to create custom validation criteria. For example, use this regular expression to ensure that ten consecutive numeric digits are entered in a phone number field:

^[0-9]{10}$

To validate a text field using a regular expression:

  1. Select the Does Not Match condition from the If Input dropdown menu.

  2. Enter the regular expression.

  3. Enter an error message in the Show Error Message field.

    Figure 4: Regular expression text validation opens up countless possibilities.

  4. Click Save Form when finished.

Validating Numeric Fields

Numeric field validation is similar to text field validation, but the conditions compare the value of the number entered to some other value.

To validate numeric fields:

  1. Select the desired condition from the If Input dropdown menu (for example, Is greater than).

  2. Enter numeric value (10) that serves as the limit.

  3. Enter an error message in the Show Error Message field.

    Numeric conditions constrain user-entered numeric data.

  4. Click Save Form when finished.

Requiring Only Integers

Forms can be configured to require numeric values to be integers. By default, the My numeric type is value is set to Decimal.

To configure the Numeric field to accept only integers:

  1. While viewing a form, click on a Numeric field to open the field configuration menu.

  2. On the Basic tab, click on the Integer radio button.

    Specify whether numbers can be decimals or integers only.

  3. Click Save Form to apply the changes.