Question
Display Logic with Text Entry
Hi,
I've seen many questions asked before that deal with Display Logic within a same page, but nothing particularly seems to address my issue. Basically, I have eight questions with two text entry boxes in each. I start off presenting the first of these questions, and have the remaining seven on the same page with Display Logic to the question immediately preceding it. So I simply want the eight questions to appear one at a time and in order, below each other on the same page as the respondent successively answers each one.
However, Qualtrics' built-in "In Page" functionality for display logic sadly does not work for text entry questions. So I'm left with each question appearing on a new page (which is not desirable for timing and general experience of filling out the survey), or attempting to make the Display Logic work myself through Javascript. But because usually, responses to questions can't easily be accessed until a page has been submitted, I'm imagining that the process to get this to work might be slightly non-trivial, specially since each question is indeed its own question in Qualtrics.
Ideally, I would simply have something like `jQuery("#"+this.questionId).hide();` on each question, and simply once the respondent has entered any response on the two text entry boxes of the question immediately preceding it (my condition is basically that the response be a number greater than 0), the question would appear, and so on for all eight questions. But I'm not sure how to access the text answers for one question in the Javascript for another question (I've tried Inspect to get an ID for the text entry boxes but I'm not sure if simply using a condition like ` jQuery(".ID").val()>0` (parsing as integer if necessary) would work (where ID is replaced with the relevant id for the text entry boxes), since each of my questions are on separate Qualtrics questions. Another alternative I could think of was to have some sort of event listener or timer that for some interval would check if the text entry boxes for the preceding question have been filled in (would using getChoiceAnswerValue from the Qualtrics Javascript API work?) to then show the new question, but I'm not sure if any of that is feasible either. Just in case, in order to randomize some things myself, I am using a matrix for these text entry questions.
Any help would be greatly appreciated! I'm at a bit of a loss here with this.
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.