NextGen FSM

Dynamic Forms - Regular Expressions

Regular Expression Node

Using this type of node, the user must fill the corresponding input field in the DC Sheet with a string, linear to the specific format specified in the “Regular Expression property”, otherwise returns a validation error and the value can’t be saved.

So regular expression node types can be used to enforce validation for user data to be inserted.

Here below some useful types of regular expression to control data.

Type

Regular Expression

Example

email

[a-zA-Z0-9_.]+@[a-zA-Z0-9-]+.[a-zA-Z]{2,3}

gino.pilotino@overit.it

Telephone number

^(\d{3})\s\d{3}-\d{4}

(###) ###-####

ISBN

Ten digits or Thirteen digits, if needed ending with the sign -

[\d*-]{10}|[\d*-]{13}

2133424424 or

3423423224244 or

123456789- or

123456789012-

 

Is also available the guide on how to compose good regular expressions.

Technical tip

Take care that the regular expression field is a text type field.

So, when you want to set an initial value on the regular expression node, it is a good idea to put it in quotes. For example, if you want to set up an email as gino.pilotino@overit.it it will be necessary to insert it as 'gino.pilotino@overit.it'.

The reason is that the expression validation engine interprets @ as a command.