Dynamic choices from repeat

Hi guys!, does anyone here can help me on my problem? I need to find a way to set the answer from repeat group into a selection.

begin repeat
Q1. Enter household members
end repeat

Q2. Who is the head on this household member
    a. Q1(first entry)
    b. Q1(second entry)

Currently my way of doing this is to change the code in xml form and it takes time to hard code it because I have similar questions like this. Is there a way to set it in excel form not changing the codes in xml file?

Thank you! :slight_smile:

Hi @diondion
Here is a sample form that shows how to do that: children.xlsx (7.0 KB)


Wooah!!! This is really amazing!! It helps me a lot! This solution saves a lot of time. Thank you @Grzesiek2010 :smile: :clap:

Hi, I tried to change it to select_multiple it doesn't work now

You just changed select_one to select_multiple? I'm pretty sure it should work. Please attach your form so that we can check what's wrong.

children.xlsx (10.6 KB)
Hi I change it to select_multiple then I tried to convert it into xlsform the error says "Error: '${names}'"

I tried to convert it into XML file*

Ah I see, there is something wrong with the converter. I would recommend converting your xls form with select_one question and then after downloading an XML version editing it manually.
To do that you need to:

  1. Open your XML form using any text editor
  2. Copy everything and paste to an XML formatted like: https://www.freeformatter.com/xml-formatter.html (this step is not a must but it makes the form readable so that you can add changes manually)
  3. Copy the formatted version back to your XML file
  4. Change select1 to select in that particular question

In your case it's in yellow:

Thank you for this but this is actually what I'm doing. For me It consumes time for doing this because I have many questions needed to edit in XML form :worried:. I really hope you can fix the select_multiple with the development team.