Survey workflow to create multiple choice question | XM Community
Skip to main content
Solved

Survey workflow to create multiple choice question

  • June 16, 2022
  • 5 replies
  • 67 views

Forum|alt.badge.img

I have a workflow that I think should be possible, but I'm striking out. Here's what I want to do

  1. Capture the survey respondent's name

  2. Use the name against a lookup table to return between 1-15 values into an array.

  3. Create a multiple choice question from the lookup array

Thoughts?

Best answer by TomG

https://community.qualtrics.com/XMcommunity/discussion/comment/47009#Comment_47009No, you can't create choices dynamically. Qualtrics won't record choices it doesn't know about in advance. You can make the choices dynamic by changing the labels through piping or JS and displaying/hiding them through display logic or JS.

5 replies

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • June 16, 2022

It is possible.
You can use JavaScript or a web service to do the lookup.
How you set up the MC question depends on your data requirements (i.e., how you are going to analyze and report it) and if you are going to use standard Qualtrics piping and display logic or are capable of writing to JavaScript to modify the question.


Forum|alt.badge.img
  • Author
  • June 16, 2022

I was thinking doing a loop and merge might be the right thing here. The webservice is easily done (already have the code). However, can you adjust a questions answers (expand and contract?). I see the display logic and that's straightforward enough, but what isn't obvious is how to create the list of choices dynamically.


TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • June 16, 2022

For the choices you can either:

  1. Pipe the labels (but you'll have to decode the data on the back end)

  2. Use all possible labels as choices with display logic on each one

  3. Use all possible labels as choices and hide the non-applicable choices with JS


Forum|alt.badge.img
  • Author
  • June 16, 2022

so for option 1, I assume you mean parse the data which isn't an issue, but then is piping the labels dynamic? i.e. it will create the multiple choice options based on the array size?


TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • Answer
  • June 16, 2022

https://community.qualtrics.com/XMcommunity/discussion/comment/47009#Comment_47009No, you can't create choices dynamically. Qualtrics won't record choices it doesn't know about in advance. You can make the choices dynamic by changing the labels through piping or JS and displaying/hiding them through display logic or JS.