I have a survey where I would like students to answer a question for each subject they took. I can pipe the subjects they took into embedded metadata (I think this needs to be a comma-separated list in a single column. For example "Physics,English,Chemistry")
I then want do a loop and merge on this field. To do this, my understanding is I need to pipe this into a hidden question so that I can use that question for the loop and merge. I am trying to use the Javascript below to accomplish this but it does not seem to record anything.
Qualtrics.SurveyEngine.addOnReady(function()
{
/*Place your JavaScript here to run when the page is fully displayed*/
jQuery('inputnid*='+this.questionId+']').val("${e://Field/Subject}")
jQuery('#'+this.questionId).hide();
this.clickNextButton();
});
Any suggestions?
Page 1 / 1
Make your hidden question a multiple choice question where the choices are all the possible subjects. Then use display logic on each choice (subject):
Embedded Data 'Subject' Contains 'X'
where X is the choice subject. Based you loop off the displayed choices in the hidden MC question.
Then your JS just needs to hide and/or click the next button.
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.