A counter that adds... and subtracts?
Apr 08, 2015
Hi all - this seems like it should be an easy feature, but apparently my brain can't handle variables right now, so I'm looking for some help.
I'd like to create a simple on-screen counter using checkboxes. Basically: have you used the tool listed on the screen? Yes or No. If they click "Used It", then the counter increases by one and they go to the next screen and then asked if they've used another tool. The counter will keep a running total. (I've gotten it to work this far)
Here is my sticking point: If they *accidentally* check "Used It" and then click it again to uncheck it, right now the variable on the checkbox continues to add 1 to the counter (ie: click "Used It" once and you get a running score of "1"... then change your mind and click the "Used It" box to uncheck it, your score goes up to "2" when it should now be equal to "0"). I can't seem to figure out how to add a second condition/variable that will subtract 1 if you click the same checkbox a second time. Suggestions?
8 Replies
Hi Brian,
What about subtracting one if the user clicks on it and the state of the checkbox is "selected" that should adjust by one and allow for the user to click back and forth.
Another option would be to check the state of either checkbox only when the Next button is clicked and based on which checkbox is selected add /subtract before jumpint to the next slide. This way, the users can change their minds as often as they want before clicking Next.
Thanks Ashley and Michael. I tried Ashley's method which seemed straight forward and I got really excited... except now it's not adding, only subtracting. Grrrrrr.
I'm attaching the file here... am I putting triggers in the wrong order? Would playing around with objects on the timeline make a difference? I've spent some time trying to play with different work-arounds, but would love some thoughts!
I prefer Michaels method, but if you use Ashley's method set your condition to evaluate equal to selected and not equal to selected, do not use equal to normal as most states are equal to normal. You may need to play around with the state conditions as they may be the reverse of what you expect it to be as the trigger may fire before the state change.
Phil Mayor, I don't know you, and I'm not a hugger, but I'd hug you right now!! Thanks. This worked like a charm.
Glad you got it working :-)
Oh gracious. Glad Brian understood this second language of conditional talk. Lol.
Glad you're finding the help you need and feel free to let us know if you have any other questions.
This discussion is closed. You can start a new discussion or contact Articulate Support.