Validating User Input in Forms

Developers can create validation and an associated error message to check the data a user enters before processing.

About Creating Validations and Error Messages

You can use validations to check data a user enters before processing. Once you create a validation and the associated error message, you can associate it with a specific item. You can choose to have validation error messages display inline (that is, on the page where the validation is performed) or on a separate error page.

Creating an inline error message involves these steps:

  • Step 1 - Create a validation and specify error message text. To learn more, see "Understanding Validations."

  • Step 2 - Associate the validation with a specific item.

Associating a Validation with a Specific Item

To associate an item with a validation and specify error message text:

  1. View the page in Page Designer:
    1. On the Workspace home page, click the App Builder icon.
    2. Select an application.
    3. Select a page.
    Page Designer appears.
  2. In Page Designer, select the Processing tab in the left pane.
  3. Under Validating, select the validation you want to associate.

    The Property Editor displays Validation attributes.

  4. Under Validation, edit the following attributes:
    • Error, Error Message - Enter the text to be displayed in the event that the validation does not pass.

    • Error, Display Location - Select where the error message displays for this validation. Validation error messages display on a separate error page, or inline with the existing page. Inline error messages display underneath the associated item label or in a notification area defined as part of the page template.

    • Error, Associated Item - Select the item where this validation error message displays. .

    Tip:

    To learn more about an attribute, select the attribute in the Property Editor and click the Help tab in the central pane.

  5. Click Save.

About the Error Message Display Location

The error message display location identifies where a validation error message displays. Validation error messages can display on an error page or inline within the existing page. Inline error messages can display in a notification area (defined as part of the page template) or within the field label.

To create a hard error that stops processes, including any remaining validations, you must display the error on an error page.