Multiple Choice question other specify | XM Community

Multiple Choice question other specify

  • 4 January 2023
  • 3 replies
  • 103 views

Hi, I'm new with Qualtrics and I have a type of question I use a lot. It looks like for example :
"Which sports do you practice? (Multiple answers allowed)
soccer ; basketball ; volleyball ; handball ; tennis ; cycling ; other specify"
I want that when people completed the Text Entry of the other specify (or when they select it), a new modality "other2 specify" appear for the question. And an "other3 specify" if "other2 specify" is selected and so on.
Is there an other way than create a new question "other2 specify" with a Display logic base on "other specify", to do that ?


3 replies

Userlevel 4
Badge +18

hi Bérengère You can create a new text entry question for each other and have a display logic on it show it appears only if previous other box is answered.
image.png
Don't forget to check "In page" option in display logic. This is how display logic will look like:

image.png

Userlevel 6
Badge +39

Hi,
You can add this javascript code to the addOnReady function :
jQuery("#"+this.questionId+" li.Selection:gt(3)").hide(); // where gt(x) is the first "other specify" choice minus 1
jQuery("#"+this.questionId+" .InputText").focus( function() {
  var isInputText = document.activeElement instanceof HTMLInputElement && document.activeElement.type == 'text';
  if (isInputText) {
      li2 = document.activeElement.parentNode.parentNode.nextSibling.nextSibling.show();
    }
  });

Thanks Guys

Leave a Reply