我已经实现了user1113568提到的脚本(即'过去可以在Qualtrics中设置setChoiceValue。是否有一个不涉及嵌入数据的解决方法?'; 1月20日18日)和D. Sam(即,在Qualtrics中,如何将关键响应保存到嵌入数据中?2月14日至17日)以质量为准,以便通过按键按压来注册响应。不幸的是,响应没有保存在我的spss数据文件中。由于质量的变化,两个脚本是否都不再有效,熟悉更新的人是谁? 任何帮助深表感谢。 最好的,Koen
脚本D. Sam In Qualtrics, how to save a key response into an embedded data?
`Qualtrics.SurveyEngine.addOnload(function()
{
this.hideNextButton();
this.hidePreviousButton();
var that = this;
Event.observe(document, 'keydown', function keydownCallback(e) {
var choiceID = null;
switch (e.keyCode) {
case 74: // 'j' was pressed
choiceID = 1;
break;
case 75: // 'k' was pressed
choiceID = 2;
break;
}
if (choiceID) {
Qualtrics.SurveyEngine.setEmbeddedData("choiceID",choiceID);
Event.stopObserving(document, 'keydown', keydownCallback);
that.setChoiceValue(choiceID, true);
that.clickNextButton();
}
});
});
`
脚本user1113568 It used to be possible to setChoiceValue in Qualtrics. Is there a workaround that does not involve embedded data?
`Qualtrics.SurveyEngine.addOnload(function()
{
this.hideNextButton();
this.hidePreviousButton();
var that = this;
Event.observe(document, 'keydown', function keydownCallback(e) {
var choiceID = null;
switch (e.keyCode) {
case 74: // 'j' was pressed
choiceID = 1;
break;
case 75: // 'k' was pressed
choiceID = 2;
break;
}
if (choiceID) {
Event.stopObserving(document, 'keydown', keydownCallback);
that.setChoiceValue(choiceID, true);
that.clickNextButton();
}
});
});
`