The validation function on form questions allows you to ensure questions are completed in a certain way, e.g. you can stop a user completing a form if they haven't answered Yes to a Yes/No question (often used as a way to prompt users to confirm that they have undertaken tasks or checks). Validations are also used to make fields/questions mandatory, i.e. a user cannot submit the form if they have left a question blank.


TABLE OF CONTENTS


Making a field mandatory

To make a field in a form mandatory, i.e. to ensure that an answer has to be submitted before the form can be marked as complete, follow the steps below:


  • Select the question that needs to be made mandatory on your middle editing canvas.
 
  • On the left hand panel, select the “Validation” tab


  • Set the validation so that the question is only valid if “it has a value


  • Enter the text that you would like to show if the user does not answer the question and tries to save the form:

  

  • Once you have done this, your validation should look like the below:


  • Click Add Rule to save it
 

You will now see the rule appearing below the validation options:


  • To remove the rule, simply click on the dustbin icon



Setting a field to require a specific answer

Below is an example of how to set a validation to request a Yes/No answer is marked Yes.


  • Select the question that needs to be answered in a set way on your middle editing canvas. In this example we will use a Yes/No question, however you can follow the same process for other question types. 
 
  • On the left hand panel, select the “Validation” tab (this is the same place as where you set if a question is mandatory or not)


  • Set the validation so that the question is only valid if “it contains the exact value”, then below it set the toggle to either YES or NO accordingly (or to the relevant answer for your scenario) - Remember, you are selecting the answer that you want them to select in order to complete the form here. E.g. if they need to answer Yes in order to complete the form, set the toggle to Yes.


  • Enter the text that you would like to show if the user does not answer the question in the right way and tries to save the form

  

  • Once you have done this, your validation should look something like the below:


  • Remember to click Add Rule to save it
 

You will now see the rule appearing below the validation options:


  • To remove the rule, simply click on the dustbin icon