Forum Discussion
MathNotermans-9
17 days agoCommunity Member
Better to share a sample...as is this is touch to debug.
One thing i always use in my Javascripts calling the lmsAPI is this function.
var lmsAPI = findLMSAPI(this);
function findLMSAPI(win) {
if (win.hasOwnProperty("GetStudentID")) {
return win;
}else if (win.parent == win) {
return null;
}else {
return findLMSAPI(win.parent);
}
}
As different LMS's handle the lmsAPI different. This to ensure you have it available.