user
@benjaminjones
Timer not working...
I'm trying to use the timer as I've succesfully incorporated it into another project.

However, in this instance, the timer is not working and although it appears, when the content is loaded it just doesn't start and won't count down.

I've tried moving the order of the triggers to resolve this, along with looking at your RISE guides to no avail.

Are you able to help if I can share my SL file or can you suggest any other tips?

Many thanks,

Ben
reply
Reply
user
@support
Ben, you can send the file using the Custom Development portal https://custom.cluelabs.com/ but most likely you have an error or a typo somewhere in a javascript trigger, likely one not even related to the widget. Storyline saves all javascript into one file, so one error in any trigger will break all other triggers in the project, even unrelated ones.
reply
Reply
user
@benjaminjones
Hi there,

Thanks for such a quick response and I can confirm I've submitted a ticket (#5662).

I appreciate the advice on the general JS code and how this can break so in the meantime I'll check over the project but hopefully hear something through the ticket support.

Thanks again!
reply
Reply
user
@support
Responding here just in case this information can be useful to someone else who's trying to troubleshoot.

In the .story file you sent, there's a trigger that loads the widget and is followed immediately by the trigger to start the timer. But Internet is not instant, even if it takes less than a second to load the widget, it's still a time lag. And Storyline has no way of knowing to not execute the second trigger until the first one finishes loading. So what you have in the end is that it attempts to start the timer before the timer loads.

If you place the initialization code on the main master instead, you will load the widget as soon as the first slide in the story loads. And by the time you need to start the timer, you know the widget will already be loaded.

Another way is to execute the second trigger a second or two after the first one, but that's very imprecise because you don't really know how fast the learner's Internet connection is, so using the master is a better option.
reply
Reply