GetStudentName function when publishing to the Tin Can API

Mar 14, 2021

It seems that the lmsAPI.GetStudentName() function doesn't work when publishing to the Tin Can API. In the attached samples, the same story is published both to SCORM 1.2 and Tin Can Api.

In the SCORM 1.2 version, clicking the blue button correctly retrieves the user name and ID. In the Tin Can API, clicking the blue button returns "undefined" and it seems you have to parse the browser query string to obtain the user name and ID (click the red button), which is messy. We are using the SCORM Cloud to test functionality. 

(The parsing code is based on the post by Prakash B "Getting student name and student id in storyline using tincan".)

Is there a better way of getting GetStudentName() to work when publishing to the Tin Can API?

4 Replies
Robert Webbe

In the meantime, it is clear to me that the described method only works if you publish in SCORM and also load it as SCORM in the LMS. There is a trick: first publish in xAPI, then publish a SCORM again, add the output of the SCORM to the xAPI output folder, make a zip file and then load it as xAPI in the LMS. The extra files make it work. But it is too much work for me to do this with every publication.

It would be nice if you had the option in Storyline to publish in both xAPI and SCORM at once. I just send it as feature request.