Forum Discussion
Display total project time using new elapsed time variables
Hi!
Ive updated Storyline and love that there are new features with the elapsed project / slide / scene built in variables.
I saw a few tutorials on how to do a few things, ie mark a course as complete when a certain time reached, or do something (ie show a layer) once a cetain time is reached. But there was a tutorial missing for one thing mentioned could be done.
Is there a way to display the elapsed time in seconds or minutes?
For example, an elearn has a duration of 30mins, and id love to display at the top the time spent so far as a count up or count down.
I tried inserting it like this... "Elapsed time: %Project.ElapsedTime% / 30mins" however the project elapsed time counts in milliseconds (in the thousands) whic is distracting. Is there a way i can use other variables or triggers to convert this counting so it displayed in seconds or minutes?
- ElearningImpactCommunity Member
Hi everyone,
I don't know if this will help, but it is possible to modify the numbers with other variables to make the numbers a little more representative (why not for a report for example).
It's not perfect, but maybe it can help.
I just created 2 new variables "minutes" and "seconds" and created a mathematical division with the triggers.
My English is not very good, the screenshot will probably be better 😉
Good day to all.
- ElearningImpactCommunity Member
- GlendaDeHoff-0cCommunity Member
Hi, Jonathan!
Have you found a way to reset elapsed time variables?
- ElearningImpactCommunity Member
Hello Glenda,
I haven't tried it, but I think this link will help you: https://community.articulate.com/discussions/articulate-storyline/resetting-slide-elapsedtime-with-a-trigger
I guess it is possible to reset them as with the other variables 🙂
Hopefully this will have been helpful to you.
- ElearningImpactCommunity Member
Hello everyone! That's an interesting comment.
There are three possible options I can think of:
- Send the value to another created variable.
- Send the value to an LRS.
- Send the value to a spreadsheet (googlesheet or datacloud).
I've already tested 2 and 3 successfully, it's interesting. And the advantage of solution 3 is that you can eventully display the spreadsheet values in Storyline (if you want to display them).
Hope this helps. Have a nice day 🙂
- PhilMayorSuper Hero
You can use some javascript something like this should work (sorry not tested):
var player = GetPlayer();
var minutes, seconds;
var timeM = player.GetVar("timeM");
function timer() {
minutes = zeros(Math.floor(timeM / 60));
seconds = zeros(timeM % 60);
totalTime = minutes + ':' + seconds;
player.SetVar("time_Display",totalTime);
}Needs variables timeM that is set from inbuilt variable and time_Display that you show on your Timer. You would need to call each second for this to update in real time
- MattPereiraCommunity Member
Hi Phil,
I am planning to use the elapsed time to report back the time spent on each section. Is it possible to access the time spent in each scene from another scene? In my case, I want to total up the time spent in each section once the user completes the activity. So i need to be able to access each scenes total duration from the end slide.
Is that something that may be possible with the latest release?
Thanks for your help!
-Matt
- FaffieKhanCommunity Member
Hi there.
My question is similar to Matt's. I want to know where to access the information on time spent per slide.
Thank you for your help.
- MariaCSStaff
Hi, Matt and Faffie.
Thank you for reaching out!
While you can't access the Scene.ElapsedTime or Slide.ElapsedTime values from a different scene/slide, one suggestion would be to assign it to a variable, which you would then display on your end slide.
This will look differently depending on how you set up the course (is the navigation restricted? How many slides are in a scene? Does the user click a button to go to another scene? etc.), but as examples:
- Set Slide1Time to variable Slide.ElapsedTime when the timeline ends on this slide.
- Set Scene1Time to variable Scene.ElapsedTime when the user clicks Next.
I hope this helps!
- GlendaDeHoff-0cCommunity Member
I am trying to hide the button that completes the course until a video (hosted on Wistia) completes using the new built-in variable - Slide.ElapsedTime., but it is not working. The variable is changing, but the button does not appear. Has anyone been able to get something like this to work? I'd greatly appreciate any input!
My code is this:
Change the state of BTN Complete Course to Normal
When Slide.Elapsed Time changes
if Slide.ElapsedTime = 5000.
- MariaCSStaff
Hi, Glenda.
Can you try changing the condition to If Slide.ElapsedTime >= 5000 ?
Let me know if this works!
- GlendaDeHoff-0cCommunity Member
Thank you, Maria! That worked.
- GlendaDeHoff-0cCommunity Member
Maria,
Is there a way to reset the elapsed time variables?
I created a timer on a slide master to track how long it takes a user to complete the quiz. It works great the first time through, but I cannot figure out how to reset it if the user wishes to take the quiz again. I tried setting Scene.ElapsedTime to zero, but my display variables rush through the first few seconds to get back to the total elapsed time for the scene. Does anyone have a suggestion? I attached an abbreviated version of the assessment below and marked the correct answers. TYIA!
- GlendaDeHoff-0cCommunity Member
I created a timer on a slide master to track how long it takes a user to complete the quiz. It works great the first time through, but I cannot figure out how to reset it if the user wishes to take the quiz again. I tried setting Scene.ElapsedTime to zero, but my display variables rush through the first few seconds to get back to the total elapsed time for the scene. Does anyone have a suggestion? I attached an abbreviated version of the assessment and marked the correct answers. TYIA!