Creating new validation routines

First, ensure that Create a new validation routine is selected within Create / Edit Validation Routine dropdown list.

Creating a new validation routine. The regular expression matches valid Master Card numbers

The Validation Title should be descriptive of what the validation routine does.

The Regular Expression is used to validate the end user’s input when applied to a text based component type. The regular expression can be as simple or complex as you require it to be in order to satisfy that the user has inputted valid data.

If you are not comfortable creating your own regular expressions you can use the Build Regular Expression button to get some guidance and test your regular expression as you build it to completion.

Regular expression builder lightbox

To use the regular expression builder you first need to enter some text that you wish to match against within the Test text area. On the bottom left hand side is a collection of common regular expression components. Single clicking on a component will bring up a brief description within the Help section.

Using help within the Regular Expression builder

As you build up your regular expression within the Expression area, it is tested against the Test text.

Regular expression builder lightbox matched text example

The blue highlighted text is the text that is matched when comparing the Expression against the Test text value. In the above example if you wanted to ensure your form user entered the word “Example” you could use the expression “[Example]” to successfully match that the user did input that value.

Example regular expressions

Validate a date is after 1950:

(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[012])\/20\d\d|(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[012])\/19[5-9]\d

Validate a valid MasterCard:

^5[1-5][0-9]{14}$

Numeric Value between 0 and 999:

^([0-9]|[1-9][0-9]|[1-9][0-9][0-9])$

When your regular expression is completed, you will need to provide some validation error messages in the various languages that you wish to support.

results matching ""

    No results matching ""