What is the ExternalConfiguration?


What is the ExternalConfiguration

You can consider the ExternalConfiguration as a tunnel through the entire process in which you can attach key|value pairs to access in various integration overrides. As the SCORM Engine progresses through its processes, the ExternalConfiguration is passed all the way through.


So what does that mean for me?

Let's say you want to use a different url to send the user to when they exit the content (RedirectOnExitUrl) for each launch. You would just add a key for that ExitUrl in your integration's ExternalConfiguration like this:

public const string DEFAULT__EXIT_URL = ""; 
public string ExitUrl = DEFAULT__EXIT_URL;

and then add to your launch url's querystring


finally, add this code block to your CLIENTNAMEIntegration file

public override string GetRedirectOnExitUrl(ExternalConfiguration externalConfig) {
CLIENTNAMEExternalConfiguration myExternalConfig = externalConfig as CLIENTNAMEExternalConfiguration;
if (myExternalConfig == null) {
throw new ScormContentPlayerApplicationException("The external configuration id argument was not a valid CLIENTNAMEExternalConfiguration object.");

if (myExternalConfig.ExitUrl != string.Empty)
return ExitUrl;
return this.GetConfigurationSetting(Constants.CONFIG_REDIRECT_ON_EXIT_URL);


Setting default values


public const string DEFAULT__EXIT_URL = string.Empty; 
public string ExitUrl = DEFAULT__EXIT_URL;

In order to set a default so it doesn't have to be passed in each time, use the keyword DEFAULT__ to prefix the const name. The SCORM Engine will treat that as the default value for the key making it optional on the querystring.

It is good practice to set defaults unless you wish to require a key|value to be passed to every SCORM Engine page (including launch and import).

Was this article helpful?
1 out of 1 found this helpful
Have more questions? Submit a request
Powered by Zendesk