Slide Timeline length
Aug 05, 2019
Is there a way to dynamically "get" the length of the time line for a slide and set it to a variable in storyline 3? Im looking to have a slide countdown timer that dynamically adjusts depending on the length of the slide and counts down as the slide progresses. I know I can use the seekbar within player features to show slide timeline progression to the learner but that's not exactly what I'm looking for.
5 Replies
Hi Christian,
Neat idea! I'll be curious to see what folks in the E-Learning Heroes community have to share here, as the slide timeline/duration is not a value currently set in a variable or accessible in a trigger.
You can get it by snooping in the DOM structure, with javascript. Here is the script snippet:
You can use
to set it to a storyline variable.
You can also access the current location by substituting
getAttribute('aria-valuemax'))
; withgetAttribute('aria-value'));
This would be a great value add! I have to be able to lock the seekbar so I can't use the video controls, which display the time.
Dear E-Learning Heroes,
@Snorre Rubin,
We've managed to import the JavaScript but it does not seem to work.
Does the Storylines player need to be ON?
Sincerely,
The Learning Hub.
Hey there, Anneleen!
Just in case Snorre is no longer subscribed here, feel free to use the Contact Me button on their profile page to reach out and reference their code!