Creating an interaction that subtracts time in pie chart?
By
Kayte F
Hi,
I am working on creating a time management course for college students. We are looking to incorporate a similar concept found on this website: http://www.studygs.net/schedule/ where users will type in the hours they spend on activities and "time" will slip away on the pie chart to showcase how they spend their day.
I am new (6 months in) to E-Learning and building courses in Storyline and I can't quite seem to figure out how to create this interaction. ANY advice would be welcomed and truly appreciated.
Thank you in advance!
Kayte
8 Replies
An interaction like this would require some simple math and custom states for the 'time slices', but it's not too difficult to set up. HereĀ is a rough example with four time categories: http://dev.keypointlearn.com/xcl71_SL/TimePie/V1/story.html. All the math is done on a separate layer, which is called when the Enter key is pressed. Based on the calculated number of remaining hours, a specific custom state of the 'time pie' element is shown. See attached the .story file. Hope that gets you started.
This is perfect - thank you so much Michael!
Hi,
Michael (or anyone willing to take a look for me) - would you mind taking a look to see what I am missing here? I am able to get the first 4 to calculate when I hit enter, but not the others. Thank you SO much in advance!
Kayte
Hi Kayte, you were VERY close
. You had added the required triggers to the calculateLayer, they were just not in the right ORDER (triggers are executed in order top to bottom). I rearranged them, so that all date entries are added up BEFORE the remaining hours are calculated.
Wow - what a rookie mistake! Haha. Thanks again for your help!
Happens to all of us Katye, but I'm glad Michael was able to get you sorted out.
Hi there! I am looping back on this piece of my project and was wondering if there was any remedy to the attached picture. If a user types in a letter the "NaN" shows up in the box and on the chart...I understand the user can just click delete or backspace and it will go away, but I am curious if there is a way to limit the box only to numbers so the "NaN" response isn't even an option? Again, probably a rookie question
Thanks for any help!
Here is some info on a possible option to check for invalid values and correct them. There is no easy, built-in way to prevent alphanumeric inputs into a numeric data field.