Submitting Rounded Score - SCORM 2004 3rd Edition
Jul 31, 2020
Hi All,
I'm trying to round my test score and submit that score to the LMS. I took the javascript example from Michael Hinze, and worked from there. I've been able to round the score and have it display correctly in my results slide.
I had some success in SCORM Cloud with the following code:
var player = GetPlayer();
var theScore=player.GetVar("theScore");
var numValue = (theScore);
var JSRoundedNum = numValue.toFixed(0);
player.SetVar("RoundedNum",JSRoundedNum);
lmsAPI.SetScore(JSRoundedNum, 100, 0);
However, when I tried that with our (LMS, Sumtoatl), it sent the unrounded score. 76.23. That was sent by the last question in the quiz, so I'm assuming my code wasn't formated correclty for the LMS to read it.
I've removed the "Submit Results" trigger from the results slide. My javascript with the rounded score should be the last score sent to the LMS.
I'm not sending "cmi.score.scaled" to the LMS. I hope that's not the issue. See the attached examples. If anyone has had success sending scores with Javascript and SCORM 3rd ed, I'd love to hear from you!
3 Replies
This post was removed by the author
I don't think I can round with SCORM 2004. I could be wrong. Thoughts are welcome.
Hey everyone. I got it working. Our LMS was using the scaled score and not the raw score when reporting to the LMS. I nixed the Storyline status and score reporting trigger and added my own javascript. Take a look... Leave a like if it helps you.
Hi Aaron,
I'm glad you were able to get it working! Thanks for sharing your solution with the community!
This discussion is closed. You can start a new discussion or contact Articulate Support.