How to Auto-advance after certain time with force response question | XM Community
Skip to main content

How to Auto-advance after certain time with force response question


Forum|alt.badge.img+1

Hi community!
How do I write a javascript to do the following:
For a page of force response questions (containing multiple choice and bipolar matrix table), after 2 min without response, automatically select the first options (of multiple choice and bipolar matrix table), and move on to the next page?

Any help is highly appreciated.
Thank you!

3 replies

Deepak
QPN Level 8 ●●●●●●●●
Forum|alt.badge.img+44
  • 1549 replies
  • October 10, 2022

DHE
I think an easier approach would be to set default choice of first option on both questions and instead of force response hide the next button and enable it on these two conditions: when either of the questions option is selected apart from default value or time spent on page is greater than 2 min.
As you would not be able to override the force response on question.
Qualtrics.SurveyEngine.addOnload(function()
{
setTimeout(function(){
jQuery("#NextButton").show();
},120000);
});
Qualtrics.SurveyEngine.addOnReady(function()
{
jQuery("#NextButton").hide();
jQuery(".SingleAnswer").on("click",function(){
jQuery("#NextButton").show();
})
jQuery(".ChoiceRow").on("click",function(){
jQuery("#NextButton").show();
})
});
Hope this helps!


Forum|alt.badge.img+1
  • Author
  • 6 replies
  • October 11, 2022

SuhasM
Qualtrics Employee
Forum|alt.badge.img+16
  • Qualtrics Employee
  • 114 replies
  • October 12, 2022

Deepak Thank you for taking time out of your day to create this custom code solution! You've gone above and beyond to help 🙂


Leave a Reply