Forum Discussion
Help with Variable
I have a slide that has several quotes on it. When you click the quote, a layer comes up with further content. There are about 15 quotes, but I want to lock the "next" button until the user has clicked at least 3.
I figure this involves a variable of some sort, but I am having trouble making it work. The slide is attached below and any assistance would be a tremendous help. THANK YOU!
- MathNotermans-9Community Member
Trying to open your file it states its made in a previous version and cannot be opened.. or is corrupt. But when having a empty .story open...it works normally ;-)
- JudyNolletSuper Hero
I was able to open the file. Here's how to disable NEXT until three quotes have been viewed.
Create a number variable with a default value of 0. For example, call it "quoteCount."
Put a trigger on each layer that adds 1 to the variable when the layer's timeline ends.
Put a trigger on the base that changes NEXT to Disabled when the timeline starts with the condition that the variable < 3.
Put a trigger on the base that changes NEXT to Normal when the variable changes with the condition that the variable = 3.
After viewing 3 layers, the variable will = 3, and NEXT will be enabled.
FYI: It’s worth the effort to learn about variables and trigger conditions, because they provide the real power in Storyline. Here’s the User Guide info:
- https://community.articulate.com/series/articulate-storyline-360/articles/articulate-storyline-360-user-guide-how-to-work-with-variables
- https://community.articulate.com/series/articulate-storyline-360/articles/articulate-storyline-360-user-guide-how-to-work-with-triggers#conditions
And here's more info about controlling NEXT: TIP: Controlling the NEXT Button 101 - Articulate Storyline Discussions - E-Learning Heroes
- MathNotermans-9Community Member
Allthough adding a variable 'amountQuotesClicked' and a trigger on each quote 'Add value 1 to amountQuotesClicked', and a condition on the Player Triggers 'if amountQuotesClicked >= 3 value 3' basically works, there are a few details to improve. Eg. you can then click 1 quote 3x to go to the next slide... and the Player buttons donot look disabled. So fixing that now.
- MathNotermans-9Community Member
And please when sharing .story files.... donot share files with guys talking that long and boring :-)
- MathNotermans-9Community Member
One other thing to fix...is disabling or hiding the next slide in the menu. As that is independent from the variables... it is always clickable. The plus of that is, i can test quicker... no need to hear that boring guy till the end :-)