Sign in
    Shared Email Templates

    Allow only specific values in custom input fields for Outlook emails

    If your Outlook email templates contain custom input fields, you can use regular expressions to make sure you and your teammates enter or select only values that match a required pattern.

    1. When creating or editing a custom input field, switch to the Advanced tab.

    2. Under Validate with regex, enter a regular expression to specify the pattern that the user input must match. For example, to allow only order IDs that start with US followed by five digits, such as US12345, enter ^US[0-9]{5}$.

      Specify the regular expression that user input must match.
    3. Select OK.

    4. Save the template.

    When you or your teammates insert the template into an Outlook email message, the add-in checks the value entered or selected in the pop-up dialog against the regular expression you specified. If the value doesn’t match, the add-in won’t insert it.

    A value that doesn't match the required pattern is marked as Invalid format.

    See also #