For a later question, I need to include the text of an earlier checkbox answer. I know to use a merge code to get the results, which will of course be a list, but I want to follow up with a random item from their checkbox answers. So several related questions:
- How do I do grab a random item from previous checkbox answers? (I think it would use sgapiExplode…)
- How do I set the text of the later question (the question itself, not the options) to include this random item? I don’t see a custom script function that allows changing the question text, just the values or options.
- Will the text of that particular question come through in the reporting, so I can see which item the respondents are addressing?
- Is there a custom script that will allow me to choose an items from a previous checkbox answer only if it’s one of several targeted items I’m interested in?
What I have so far is this as my later question text: Describe the hardest part of [question(“value”), id=”20″,case=”lower”]?
Question 20 is a checkbox question, and if they check more than one, the merge code will be replaced with something like “blue,green” in the question text.
@research : You can change the question text using sgapiSetTitle:
Though you are correct that, this would not be accounted for in reporting.
Given what you are describing above I wonder if the built-in question repeating feature would work for you? Using this feature you can repeat later questions for each selected answer in a previous questions. You can also exclude certain options from being piped. Piping would also give you the reporting you need; that is, there would be an instance of the question per option.
Here is a tutorial with more info:
I hope this helps!
SurveyGizmo Customer Experience Team