JavaScript to Storyline
I have been researching for a couple days now, and I have found some good JavaScript code for pulling information from the LMS and putting it into variables in my slide. I have been able to get this to work with Scorm Cloud, but as soon as i put it in Adobe Learning Manager, it no longer works. I have been trying to find what I need to do to make it specific to my LMS, but have had no luck.
In short, I want a certificate of completion that pulls in the learner name and course name. Anyone had success with this in Adobe Learning Manager and Storyline? Or know what I might be doing wrong? Below is the code I am using:
var player = GetPlayer();
var myName = lmsAPI.GetStudentName();
var array = myName.split(',');
var newName = array[1] + ' ' + array[0];
player.SetVar("lmsName", newName);
//myName = player.GetVar('myName');
//player.SetVar("lmsName", newName);
