For a particular question I have, I find that I need to put Qualtrics.SurveyEngine.addOnUnload() within Qualtrics.SurveyEngine.addOnReady(). The solution seems to work, but I am a bit unsure if this might cause other problems. As such, I'd like to ask experts here the following questions.
1) Will there be problems if put addOnUnload() inside addOnReady()? My code structure looks like:
Qualtrics.SurveyEngine.addOnReady(function(){
Some complicated event listener that calls this.enableNextButton()
Qualtrics.SurveyEngine.addOnUnload(function(){
Remove event listener
});
});
2) There is another object that I need to remove on unload. To keep things neater, I want to put that after the closing of addOnReady(). Hence, I will have two addOnUnload() blocks. Will that cause problems?
Position of addOnUnload
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
