Using JavaScript to Automatically Run Storyline in Test Mode During Review

I recently had a request to create a "test mode" for Articulate Storyline courses by my SMEs when they are reviewing courses online at Articulate 360. I could manually do this, but with the number of courses I manage, I felt a needed an automatic method to minimize issues (and not accidentally publish a Test Mode course to learners).

The Test Mode allows for SMEs to navigate freely in the course and to not be restricted to a locked down Main Menu. The Main Menu contains buttons for each section, and the learner must complete each section before continuing (tracked by custom variables).

I thought I'd share my solution in case other developers wish to use a system like this.

Create variables:

  • var_currentHost (text)
  • var_testMode (true/false)

Slide #1:

  1. Execute JavaScript as the top Trigger:

var currentHost = window.location.hostname
var player = GetPlayer();

  1. Create Layer: Test Mode Indicator with visual indicator/instructions for course running in Test mode for SMEs.
  2. Add Trigger: Show layer Test Mode Indicator When the timeline starts If var_currentHost is equal to Note: this is the returned value - I had expected though!

Main Menu: 

  1. Create Layer: Test Mode.
    • Display text box indicator/instructions for course running in test mode for SMEs.
    • Add triggers change menu variables to unlock all menu buttons. In my case: "Set my var_Section1 equal to True when the timeline starts."

I cannot provide a .story because of the proprietary content... sorry about that.

Todd Haynes

1 Reply
Andrew Hanley

Only seeing your post now Todd.

This sounds exactly what Im trying to achieve, but unfortunately I follow your instructions right up till the very last point :D

"...Add triggers change menu variables to unlock all menu buttons..."

Is this using a standard Storyline MENU, and if so, can you ellaborate a bit on how you are unlocking these?

Thanks so much!