Hi, Paul,
well, it can be done, but be aware that it's at your own risk [:)]
1. Do not use onAttempt event for that - it will make object work incorrect! OnAttempt fires BEFORE any current answer evaluation and if you change object state on this step it can produce errors.
2. Use OnQuestionEnd event (it fires when all evaluations on current question are done and nothing left to do with this question). Use JAVASCRIPT action with call, similar to call of Next Question button (i.e. you will emulate the click on the button):
CallMethod('q_099_test', 'Dispatcher', { pid: 'here goes real test object ID', action: 'clicknext'});
3. You will also need to check if the question is last and DO NOT launch on the end of last question (normally the object scripts do that, but if you override them, then you should take care of that). Something like (suggest you have 15 questions in test):
IF ($OBJ_ID.questionNumber!=15)
_ JAVASCRIPT (...from p.2...)
Anyway, it's a kinda hack. Be careful and check it twice.
Hi, Paul,
well, it can be done, but be aware that it's at your own risk [:)]
1. Do not use onAttempt event for that - it will make object work incorrect! OnAttempt fires BEFORE any current answer evaluation and if you change object state on this step it can produce errors.
2. Use OnQuestionEnd event (it fires when all evaluations on current question are done and nothing left to do with this question). Use JAVASCRIPT action with call, similar to call of Next Question button (i.e. you will emulate the click on the button):
CallMethod('q_099_test', 'Dispatcher', { pid: 'here goes real test object ID', action: 'clicknext'});
3. You will also need to check if the question is last and DO NOT launch on the end of last question (normally the object scripts do that, but if you override them, then you should take care of that). Something like (suggest you have 15 questions in test):
IF ($OBJ_ID.questionNumber!=15)
_ JAVASCRIPT (...from p.2...)
Anyway, it's a kinda hack. Be careful and check it twice.