I'd like to brand courses based on user. I'm under the impression I'll need to work with the 'cpQuizInfoStudentID' variable to accomplish this.
For now I'm just trying to get the variable to display. I made a text caption with $$cpQuizInfoStudentID$$ but I can't seem to get it to display any value. Any reason why? Do I need to do something specific to get that value into the course? Do I actually need to complete a quiz before this variable is populated in captivate?
I've tried publishing this course in cap. 8, Uploaded it to scormcloud via my LMS api. I lauch from my LMS but it's just blank in text caption where $$cpQuizInfoStudentID$$ should be.
The variable cpQuizInfoStudentName should be populated (if the connection with LMS is OK) when a user logs in, with its login user name. Did you try that variable with a LMS? The variable you used is for Internal Server reporting, not sure it gets populated when you use a LMS.
Hi Lilybiri, as mentioned above, I am launching the through my LMS through the course list of a specific user. The lms recorded that the course was started for that user. Are you saying I need to specifically send that variable from my LMS?
No, I did tell you to use cpQuizInfoStudentName, not cpQuizInfoStudentID. Was that not clear in my previous answer? If you read the description of both variables, maybe you'll understand?
As Lilybiri pointed out, cpQuizInfoStudentName will be there automatically.
The course grabs its value from an LMS when it first initiates the session.
For cpQuizInfoStudentID, if you really want to use that, you need to GET the value first yourself.
How you do that depends on which standard you're publishing too (e.g. SCORM2004_CallGetValue, SCORM_CallLMSGetValue, etc...).
Much easier to use cpQuizInfoStudentName.
Hope that helps.
Sorry Lilybiri as the first bunch of characters in the two different variables are the same, I miss-read what you were saying. I can get cpQuizInfoStudentName to display Thank you.
@Russ_E good to know there are specific requirements for cpQuizInfoStudentID. I agree it would be much easier to use cpQuizInfoStudentName, but that value is not necessarily a unique identifier is it? If I had two John Smith's in my system, I wouldn't be able to identify which one was running the course would I?
I'm publishing to scorm 2004, so I'll search around for how to use SCORM2004_CallGetValue.
Took me awhile to sort out the proper script to use. Thought I'd leave a trail here of what I did.
To get the variable in captivate i used: window.cpAPIInterface.setVariableValue("studentID", SCORM2004_GetStudentID());
studentID is my own user variable and SCORM2004_GetStudentID() is a function defined in scormdriver.js
Ultimately I wanted to use this variable in a web object so I can display a custom logo. to do that I used: StudentID = window.top.SCORM2004_GetStudentID(); within the web page displayed by the web object.
As some of these files may be dispatched to alternate LMSs that might use different scorm versions, I imagine my next step will be to check the scorm version and choose the appropriate get value function.
I realize this is pretty old but I thought this might help future vistors.
If you don't know (or care) which version of SCORM/xAPI etc you are using then you can simplify the call by using: