Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

If you want to To define a default response to a question, use the "Default Data Value" field in the logic section of a question . You can set the default value for (for more information on using logic in CommCare visit the Common Logic and Calculations page). Set the Default Data Value for a question to be a case property of your choosingThis will Default Data Values also even work for multi-select questions, if the  value value loaded into the multi-select question is a string of the Question ID's of the desired default responses desired , separated by spaces.

This functionality could be is useful, for example, if you want to have an Update Registration or Modify Registration form that defaults the response to a given question entered at registration. SoFor example, say if you have a registration form with a Multi-Select question to find out the occupation of a woman and during registration you check-marked three of the choices: farmer, seamstress, and hairdresser. The response to this question could be saved in the case property as something like 'farmer seamstress hairdresser'. If you default the question to that case property, 'farmer' 'seamstress' and 'hairdresser' will show up pre-checked.