Javascript examples

Mar 20, 2014

Hi there! I need to build a course with quizzing paths. Another way of saying it is that i need to include some additional questions if a person falls into category 'b' and not if they are in category 'a'.

My thought is to build the quiz 'a' in one path and quiz 'b' in another. Add a results slide 'c' that includes both 'a' and 'b' results. When a person selects that they are 'a' and of course will not complete the questions in quiz 'b' - I want to set that quiz value to 100% without them answering those questions.

I think i am close by insertign a javascript that would set that quiz value 'b' to 100% but i need some javascript examples to follow.

Thoughts? or examples 

4 Replies
Michael Hinze

Jami Moss said:

Thanks Michael! It doesn't appear that set the value of a default Storyline variable (i.e. Results.ScorePoints). Is that correct?

The results-related variables (e.g. Results.ScorePoints) are read-only and cannot be set by either triggers or JavaScript. There are options to report the value of a custom score to an LMS, here is one thread with a Javascript snippet.

This discussion is closed. You can start a new discussion or contact Articulate Support.