Difference between revisions of "Relevance Condition to Multiple Fields"

Jump to: navigation, search
Line 2: Line 2:


Here
Here
== Code example ==
Here is a [https://docs.google.com/spreadsheets/d/17U64Bu3oUyfa8MmJ7_tM8DQ5_ZUO_MPzx9vT28hfpgk code example] that shows how a group is used so that the relevance condition does not have to be applied to each field inside the group.


Not that there is no problem to have a field to be required that is not always shown. Required mean that '''''if''''' the field is displayed then data needs to be recorded for this field before the enumerator is allowed to swipe pass this question.
Not that there is no problem to have a field to be required that is not always shown. Required mean that '''''if''''' the field is displayed then data needs to be recorded for this field before the enumerator is allowed to swipe pass this question.


[[Category: SurveyCTO Coding Practices ]]
[[Category: SurveyCTO Coding Practices ]]

Revision as of 23:50, 12 February 2017

If you want to apply the same relevance code to multiple fields you should not copy your code. Copying the same code to a couple of fields could be OK depending on personal preference, but copying to 5 or more fields should always be avoided.

Here


Code example

Here is a code example that shows how a group is used so that the relevance condition does not have to be applied to each field inside the group.

Not that there is no problem to have a field to be required that is not always shown. Required mean that if the field is displayed then data needs to be recorded for this field before the enumerator is allowed to swipe pass this question.