required fields in form with relevant expressions

256
3
02-13-2024 11:07 AM
clt_cabq
Occasional Contributor III

In a form I am working on i have some questions that are exposed based on a relevant expression. When the expression is true, some of those questions are required. Would it be a best practice to have those required fields populated with something like "NA" in situations where the expression is false and thus the questions aren't displayed?

0 Kudos
3 Replies
DougBrowning
MVP Esteemed Contributor

Typically you would use Relevant for this.  Then the question does not even show and gets stored as a Null in the database.

0 Kudos
clt_cabq
Occasional Contributor III

The problem I am running into is the questions are in a repeat; there is some chance that a survey completed in one instance at a location where the relevant expressions are false could be visited at another time where those same conditions prove true. When that happens, the null in the required field will prevent additional repeat records to be collected. 

0 Kudos
DougBrowning
MVP Esteemed Contributor

A required will not fire if the field is hidden due to a relevant.  So you should be ok.

0 Kudos