Forum Discussion
AdamTrosper
8 years agoCommunity Member
lmsAPI Functionality in HTML5 Output
Hey all,
I've been searching through the forums and haven't been able to find anything solid. I'm using Storyline 360, outputting to both HTML5 and Flash to cover my bases, since the audience doe...
DerrickThomas
4 years agoCommunity Member
Hi everyone,
I am trying to pull the username from Canvas for a storyline 360 certificate but I'm having a bunch of trouble.
I am using javascript but cannot seem to get it right. Here is what I have in my script:
var name = lmsAPI.GetStudentName();
var nameArray = name.split(", ");
var firstName = nameArray[1];
var lastName = nameArray[0];
var player = GetPlayer();
player.SetVar('first_name',firstName);
player.SetVar('last_name',lastName);
then I print the name using
%firstName”%
%lastName%
Any help will be appreciated.
Thanks