Automatic forwarding to next page from matrix | XM Community
Skip to main content
Solved

Automatic forwarding to next page from matrix

  • March 26, 2020
  • 3 replies
  • 28 views

Forum|alt.badge.img
Hi, I am trying to automatically forward to the next page in my survey (without having to click the next button). I know the Javascript code for this is usually: Qualtrics.SurveyEngine.addOnReady(function() { var that = this; var answers = $$(".SingleAnswer"); for(var x = 0; x<answers.length;x++){ answers[x].observe('click', function(event) { that.clickNextButton(); }); } }); This works perfectly fine with single questions, but not with a matrix. Anyone can help me out? So just to be clear: Final question on the page that would include the code is a matrix (so multiple questions combined). Thanks a lot!

Best answer by TomG

Count the number of choice rows in the matrix. On each click count the number of answers selected, then click next if it equals the number of choice rows.

3 replies

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • Answer
  • March 26, 2020
Count the number of choice rows in the matrix. On each click count the number of answers selected, then click next if it equals the number of choice rows.

rondev
Level 6 ●●●●●●
Forum|alt.badge.img+22
  • Level 6 ●●●●●●
  • March 26, 2020
Also, what if someone misses another question on that page, so you need to check that too, before clicking next button

Forum|alt.badge.img
  • Author
  • March 27, 2020
@TomG Thanks! Can you show me what the Javascript code would look like for a matrix with 2 statements, 7 answer-options (so 7 choice rows?), single-answer for each statement. Would help me a lot :)