ReviewMyElearning.com

Preventing Resume after Articulate Course Completion

Articulate has a wonderful feature that if turned on will ask the student they want to resume the course when they left off. Sometimes you may decide to turn this off and force a student to begin all over again but most of the time we course developers leave it on.
But there are a few times that you wish you could force a student to start over if they have already completed the course. For instance… let’s say you have a course and separate quiz. The student must complete course in order to move on the quiz. But if the student fails the quiz and goes back to the review the content you may not want them to resume… on the last slide. In fact I would venture to guess that if a student has completed a course you wouldn’t want them to resume on the last slide… so why ask them? Plus, if you have restricted your navigation to force students to move linearly through the course you might not want to let move freely just because they got to the end once; particularly if they failed the quiz.
So here is the solution, and it only takes a few lines of JavaScript. Open up your player.html file in your favorite text editor and find this JavaScript function (around line 368):

if (g_bLMS)
	{
		if (g_bAPIPresent && !g_bAOSupport)
		{
			RetrieveStateData();
			strFlashVars += "&vResumeSlide=" + String(g_SlideLastViewed);
			strFlashVars += "&vStateData=" + String(g_strResumeData);
			strFlashVars += "&vLMSPresent=" + String(g_bLMSPresent);
		}
	} 


This is where Articulate gets the resume data. What we want to do is say… “if this course has been completed please reset the slide viewed and remove all the resume data.” We can do this with some of Articulate’s built in JavaScript variables.

if(g_bLessonCompleted){
  g_SlideLastViewed =1
  g_strResumeData = ""
}


That variable “g_bLessonCompleted” tells us if the course has been completed (true/false). And if it has reset some of Articulate’s other variables. We need to do all this after the data has been grabbed from the LMS and before they are passed on to the player. So we put our code between “RetrieveStateData();” and before the “strFlashVars” is appended. Like so:

if (g_bLMS)
	{
		if (g_bAPIPresent && !g_bAOSupport)
		{
			RetrieveStateData();
			if(g_bLessonCompleted){
				g_SlideLastViewed =1
				g_strResumeData = ""
			}
			strFlashVars += "&vResumeSlide=" + String(g_SlideLastViewed);
			strFlashVars += "&vStateData=" + String(g_strResumeData);
			strFlashVars += "&vLMSPresent=" + String(g_bLMSPresent);
		}
	}


Ta Da! That’s it.
Remember to check out eLearning Enhanced for prebuilt Articulate Widgets and contact us with your Articulate wish list. We love building custom solutions.

Comments

The resume action you created for me did not work since the code var g_bLMS = true must be var g_bLMS = false in order for my Articulate file to load in our ANGEL LMS environment. This variable is also used before (around line 364) and after the place where the 3 new lines of code were entered. Any suggestions would be appreciated.

eLearning Enhanced is awesome

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
  • Images can be added to this post.
  • You may use [inline:xx] tags to display uploaded files or images inline.
  • You may use <swf file="song.mp3"> to display Flash files inline
  • Twitter-style @usersnames are linked to their Twitter account pages.
  • Twitter-style #hashtags are linked to search.twitter.com.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
  _           _      _           _        _  _  _  _                          _           _    
(_)_ _(_) (_) _ (_) _(_)(_)(_)(_)_ (_) _ _ (_)
(_)_ _(_) (_) _ (_) (_) (_) _ _ _ _ (_)(_) (_)(_)
(_)_(_) (_) _ (_) _ _(_) (_)(_)(_)(_)_ (_) (_)_(_) (_)
(_) (_)(_) _ (_)(_)_ (_) _ _ _ (_) (_) (_) (_)
(_) (_) (_) _ _ (_) (_)(_)(_)(_)(_) (_) (_)
(_) (_) (_) _ (_)_ _ _ _(_) (_)_ _ _ _ (_) (_)
(_) (_) (_) (_)(_)(_)(_) (_)(_)(_)(_) (_) (_)

Enter the code depicted in ASCII art style.