Good afternoon,
I have an audio file loaded into one of my questions. I am running a Stop-Signal measure. I have instructed the participants to press the spacebar when they would like to stop the audiotape (the audiotape does not actually need to stop, I just need to know when they would stop it). Therefore, I need to record 1) the time someone presses play and 2) record the time from the play button press until they press the space bar. I have set this javascript on both the question and a timing block:
Qualtrics.SurveyEngine.addOnReady(function() {
var start = new Date();
function getTime(e)
{ e = e || window.event;
var key = e.which || e.keyCode;
if(key===32){
var t = new Date() - start;
Qualtrics.SurveyEngine.setEmbeddedData( 'embeddedsolutiontime', t)
alert(t);
document.removeEventListener('keydown', getTime);
window.top.document.removeEventListener('keydown', getTime);
}
}
document.addEventListener("keydown", getTime);
window.top.document.addEventListener('keydown', getTime);
});
However, I can only get the first click (play button) and last click (arrow button for next page), I'm not getting the results for the spacebar.
I also think that if I can't get this type of recording, I could try to have the audio play automatically once they click onto that page, therefore the spacebar would be the first click, which Qualtrics timer settings do easily. How would I get the audio to play automatically instead of having to click the play button?
Any help with either of these two would be greatly appreciated!
Recording time
Sign up
Already have an account? Login
Welcome! To join the Qualtrics Experience Community, log in with your existing Qualtrics credentials below.
Confirm your username, share a bit about yourself, Once your account has been approved by our admins then you're ready to explore and connect .
Free trial account? No problem. Log in with your trial credentials to join.
No free trial account? No problem! Register here
Already a member? Hi and welcome back! We're glad you're here 🙂
You will see the Qualtrics login page briefly before being taken to the Experience Community
Login with Qualtrics
Welcome! To join the Qualtrics Experience Community, log in with your existing Qualtrics credentials below.
Confirm your username, share a bit about yourself, Once your account has been approved by our admins then you're ready to explore and connect .
Free trial account? No problem. Log in with your trial credentials to join. No free trial account? No problem! Register here
Already a member? Hi and welcome back! We're glad you're here 🙂
You will see the Qualtrics login page briefly before being taken to the Experience Community
Login to the Community
Welcome! To join the Qualtrics Experience Community, log in with your existing Qualtrics credentials below.
Confirm your username, share a bit about yourself, Once your account has been approved by our admins then you're ready to explore and connect .
Free trial account? No problem. Log in with your trial credentials to join.
No free trial account? No problem! Register here
Already a member? Hi and welcome back! We're glad you're here 🙂
You will see the Qualtrics login page briefly before being taken to the Experience Community
Login with Qualtrics
Welcome! To join the Qualtrics Experience Community, log in with your existing Qualtrics credentials below.
Confirm your username, share a bit about yourself, Once your account has been approved by our admins then you're ready to explore and connect .
Free trial account? No problem. Log in with your trial credentials to join. No free trial account? No problem! Register here
Already a member? Hi and welcome back! We're glad you're here 🙂
You will see the Qualtrics login page briefly before being taken to the Experience Community
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
