Skip to main content
Participant
Oct 2, 2017 9:48 AM UTC
Question

Captivate export. Js error

Hello

I'am trying to play a captivate export. But when i load the index_scorm.html i have this error in the js console.

Uncaught TypeError: Cannot read property 'charAt' of undefined

    at cp.QuizState.readNumber (CPM.js:1320)

    at cp.QuizState.readString (CPM.js:1322)

    at cp.PlaybackController.restoreObjectsFromState (CPM.js:1398)

    at Function.cp.resumeValuesFromDataChunk (CPM.js:1315)

    at cp.PlaybackController.RestoreQuizState (CPM.js:1439)

    at Function.cp.NewQuizLibraryInit (CPM.js:1014)

    at Function.cp.CPPreInit (CPM.js:1022)

    at Function.cp.ContinueCPInit (CPM.js:2192)

    at LoadContent (CPM.js:1314)

    at InitializeExecuted (scormdriver.js:1879)

the module it's not play on a LMS. I have my own wrapper to get scorm data.

Somebody did have this error ?

This topic is closed to new replies. Start a new post to keep the conversation going.

4 replies

RodWard
Community Expert
Community Expert
Oct 2, 2017 10:35 AM UTC

Upload the SCORM zip file to SCORM Cloud and test whether you get the same issue there.  If it does work fine, then the issue is not with the Captivate file but must be either with your web server or your own JS code.

Translate
Participant
Oct 2, 2017 2:18 PM UTC

I test on Scorm Cloud like you said it is working.

But the think that i don't understand it i test the same wrapper on another Captivate Module and i don't have the pb.

For the moment the js wrapper look like :

var API = new MyApi();

    function MyApi() {

    this.LMSInitialize = function() {

console.log('LMSInitialize');

};

this.LMSGetValue = function() {

};

this.LMSGetLastError = function() {

cp.

};

this.LMSGetErrorString = function() {

};

this.LMSGetDiagnostic  = function() {

}

this.LMSSetValue = function(k, v) {

alert(k)

}

    };

I set an alert in LMSSetValue and i see the first key is cmi.core.exit and the value is suspend i don't know if it is normal

Translate
Raymond_Ford
Participating Frequently
Apr 2, 2019 3:23 PM UTC

Did you ever figure it out?

Translate