Archive for January, 2007

Using Flash V2 Components in a Course

Monday, January 15th, 2007

Flash 8 provides a set of components that make it easy to create interactivity in an e-learning course (the newer set of components in Flash are the version 2 or V2 components). One of the things you will need to know to use V2 components is the way Flash loads components and when ActionScript is called from listeners and frames. Here is a scenario that will give you an insight on the use of components in a course:

Scenario: Your course provides “next” and “previous” buttons that let the learner move forward and backward in the course. In Flash, you would have listener functions that process the click events for the ”next” and “previous” buttons. In the listener function for the “next” button you may want to load another part of the user interface in the course (for example, you may want to load a multiple choice question). A good way to load the user interface is to call gotoAndStop(name-of-frame). This frame would contain the components that  present a multiple choice question to the learner.

To make sure your course works correctly you should NOT set or get any of the properties of the components immediately after your call to the gotoAndStop() function. However, your components are not fully loaded until the frame with those components is loaded. So, if you need to get or set properties on those components you should do so in code executed from the loaded frame. You should not get or set the properties inside the listener of your “next” button.

Running JavaScript on your local computer

Monday, January 15th, 2007

Windows XP SP2 and Windows Vista will not let you run JavaScript from your local hard drive or CD-ROM. This restriction can make it difficult to distribute interactive web pages for use on a local computer. When you launch a HTML page with JavaScript on your computer, Internet Explorer 6 and 7 will tell you that the page contains Active Content. You have to authorize the page to run “Active Content” each time it is loaded or you have to change the default settings in “Internet Options…”

Microsoft has provided a work around for this problem. The HTML author can add the “Mark of the Web” (MOTW) to each HTML document. The MOTW is a comment line included in the HTML code. Here is a sample:

<!-- saved from url=(0014)about:internet -->

Creating a SCO with a HTML Frameset

Thursday, January 4th, 2007

Here is the general way to create a SCO using a HTML frameset.

Your frameset will contain some or all of the code for your SCO. Your frameset will have the code to get and set the bookmark. Your frameset can also have the code to set the completion status, success status, score and other SCORM data items. Your frameset will contain at least one frame. You will display the content (HTML pages) of your SCO in a frame.

The frameset will initially display a blank page when it is loaded. Your frameset displays a blank page because it has to find out if this is the first time the learner has launched the SCO. If this is the first time the SCO is launched, the frameset will load the first page in the SCO into the frame. If the SCO has been launched at least once, your frameset will get the bookmark (previously saved by your SCO) and then use that bookmark to load the correct page.

In a SCORM 2004 SCO, your frameset can save the bookmark information in cmi.location or cmi.suspend_data. In a SCORM 1.2 SCO, your frameset can save the bookmark information in cmi.core.lesson_location or cmi.suspend_data. You will decide what kind of information to store in the bookmark. For example, you could store the name of the file that was previously viewed by the learner. You could also store a number that could be an index to an array of pages that you load when the SCO is launched.

We have created an e-learning toolkit that uses a frameset to manage bookmarks within a SCO. The toolkit comes with source code that you can use “as is” or modify to meet your specific needs.