how to read the passing grade
October 23, 2013 12:00 AM
Although I can manually create a variable on passing grade, I wonder if the value is somewhere I can retrieve.
There are 2 places with that info:
1. the XML file with all questions, answers- it has one item 80
2. trivantis-titlemgr.js- TTPr.loadTestFile = function( nl ) with line: this.iPassGrade = getNVInt( nl, 'passinggrade', this.iPassGrade );
How can get the info from action?
Thanks,
Discussion (1)
Sure. Two lines of JS:
var xxx = getTitleMgrHandle();
Var_myCustomVariableInLectora.set(xxx.arTests[0].iPassGrade);
Assuming you have a Lectora variable called myCustomVariableInLectora and it has been used in any action/condition on the page (so that it's instantiated).
Also, only works when tests work, i.e. on a webserver, otherwise loading the XML fails.
Judging from your expertise on the forums, you know what to do with this information. Let me know if you need any help though :)
Cheers,
Sergey
Discussions have been disabled for this post