Hello!
In my survey, I want participants to answer a math problem and key-in an answer. Right now I have it set up to automatically advance to the next question if they do not fill in the single line free response box after 5 seconds. However, is there a way to code qualtrics so the participant doesn't have to click on the response box in order to type in an answer? Is it possible for the participant to just type in an answer and hit enter to move on to the next problem? I have each problem set up as a separate block now. I am hoping to make it so the participant doesn't have to move the mouse at all to complete this timed survey. It would be great if, to answer, all they had to do was type in an answer and hit enter or let the screen time out.
Page 1 / 1
```
Qualtrics.SurveyEngine.addOnReady(function() {
var input = jQuery("#"+this.questionId+" input[type=text]");
input.select().focus(); //works on desktop, but not on all mobile browsers
input.keydown(function(e) { if(e.which == 13) jQuery("#NextButton").click(); });
});
```
Qualtrics.SurveyEngine.addOnReady(function() {
var input = jQuery("#"+this.questionId+" input[type=text]");
input.select().focus(); //works on desktop, but not on all mobile browsers
input.keydown(function(e) { if(e.which == 13) jQuery("#NextButton").click(); });
});
```
Thank you so much!! It worked!! I really appreciate your help!!
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.