When using Device Magic, it is sometimes useful to validate an answer for a certain field. When you set a validation rule, a form may not be submitted until the correct answer has been entered for that field. Below, I show you how to set this rule.
Firstly, open the form builder and select the question in which you'd like to validate. Then, select the 'Show Advanced Settings' checkbox.
Next, click the 'Validate Value' checkbox. You can then choose the condition for your answer by clicking 'set rule'.
Next, change the field to the one desired by selecting it from the drop down. For this example I chose ">" in the drop down menu to the right of the "Change field" link. Lastly, I typed in "2".
After clicking save, I typed the error message that I wanted to appear when a number greater than "2" was not submitted within the form.
When the question is filled in with a quantity less than 2 on a mobile device, a box will pop up notifying you with the error message. You will need to re-enter the answer correctly in order to be able to submit the form.
- The conditions you set up must be met (true), in order for the user to be able to submit the form.
- Validations will only be checked once the user clicks the "Submit" button.
- For more complex validations, check out this article here.
Other Useful Articles: