How to use a true/false variable to track whether a certain event has occurred, then let learners proceed to the next slide only when the variable is true.
I'm trying to have the "NEXT" button become normal when the Learner clicks on all 4 buttons. They should have to click on each button before the "NEXT" button becomes active for them to proceed. Can someone please refer me to a tutorial or offer some advice on how to get this functioning working correctly? I don't seem to understand how the true/false variable works. Thanks for any help I can get. I have attached the project. Each slide layer contains audio and will contain images and text but I haven't gotten that far. I wanted to get the functionality working first.
Have a look at the attached file and see if that's what you want. I added a T/F variabe that is set to True when all four ? buttons are Visited and the media on each layer completed playing. based on this changing variable, I 'turn on' the Next button and display the hint caption (which I moved to the baselayer). Hope that makes sense.
Michael, thank you! That is exactly what I was trying to accomplish. I really need to get a handle of Variables. Is there any documentation or tutorials that you can recommend?
I went ahead and used your slide as a template for another in the same course that I'm building and I have run into a problem which I can't figure out.
The first slide works great but than when you click "NEXT" and it lands on the next set of clickables, the variable is automatically set to "TRUE" so when the Learner clicks on the 4 questions and listens to the answers, the "Click NEXT" nor the "NEXT" button become active due to the slide already thinking it's 'True.'
How can I set up the second slide so that it doesn't automatically think that it's true?
You'd need to reset the variable or use a new variable for that slide. If you're going to reset it, you'll want to use a trigger such as "reset variable when the slide timeline starts of slide X" or similar.
Thank you for your response. I went ahead and created a new variable but it's still not working. The slide still thinks it's 'True' even after I created the new variable.
I have enclosed the slides for you to take a look at, if you're so kind to.
variables are used globally in SL not on a slide by slide basis. So if you start with a T/F variable that has a default of 'False' and you trigger it to True on say Slide 2 - it will remain in that True state for the rest of the project even if you 'reset the slide to initial state' when revisited. You have to trigger the variable back to false for it to be used again - hence Ashley's comment above to reset the variable.
On your first slide, I created a trigger, Adjust variable 'complete' to value 'true' when state of all 'your four ? marks are visited'. This changes the variable to true and the next button to enabled.
On your second slide I created a trigger, Adjust variable 'complete' to value 'false' when the timeline starts on Slide 2...this way your variable is ready for the next set of instructions to turn it to true on slide 2.
Is it possible to add this variable reset to the master slide? When I tried that it added a layer to the master slide which I think is complicating things....
If you're using the variable on a master slide, it would be resetting any slides that are using that master so it could become problematic.
Adding a trigger or similar to a master slide shouldn't automatically create a new slide master layer for you - so I'd also want to confirm that you're working on local project files as described here.
I realised I had copied/pasted the trigger from a slide to the master which appears to be what was causing the new layer to appear - when I created it directly it worked beautifully. However, as you suggested, my logic was flawed and it *did* create a problem so I've done the variable reset on each slide instead.
Hi Michael, a very good help. Just wondering here. with your setting, the next button will be disabled when we click previous button (revisiting the slide) any idea how to enable the next button when revisiting it?
I duplicate the slide to provide better understanding
Really need a quick solution here, which I already posted my question earlier too. From Michael's answer, is there anyway I could enable the next button when click previous/revisiting the slide? duplicate the slide from Omar just for an example
You need a separate variable for each slide (in addition to "Complete") to indicate if this is the first visit to the slide. For example "Slide1Visited". When "Complete" is set to True, also set "Slide1Visited" to True.
Then add the condition "If Slide1Visited is equal to False" to the trigger that hides the Next button when the slide opens. When you return to the slide, the Next button will not be hidden.
19 Replies
Have a look at the attached file and see if that's what you want. I added a T/F variabe that is set to True when all four ? buttons are Visited and the media on each layer completed playing. based on this changing variable, I 'turn on' the Next button and display the hint caption (which I moved to the baselayer). Hope that makes sense.
Michael, thank you! That is exactly what I was trying to accomplish. I really need to get a handle of Variables. Is there any documentation or tutorials that you can recommend?
Thanks again!
There is some info on T/F variables here.
Awesome job, Michael -- your assistance is appreciated! :)
Thanks Michael,
I went ahead and used your slide as a template for another in the same course that I'm building and I have run into a problem which I can't figure out.
The first slide works great but than when you click "NEXT" and it lands on the next set of clickables, the variable is automatically set to "TRUE" so when the Learner clicks on the 4 questions and listens to the answers, the "Click NEXT" nor the "NEXT" button become active due to the slide already thinking it's 'True.'
How can I set up the second slide so that it doesn't automatically think that it's true?
Thank you for any help that you can provide.
Hi Omar,
You'd need to reset the variable or use a new variable for that slide. If you're going to reset it, you'll want to use a trigger such as "reset variable when the slide timeline starts of slide X" or similar.
Hope that helps!
Hi Ashley,
Thank you for your response. I went ahead and created a new variable but it's still not working. The slide still thinks it's 'True' even after I created the new variable.
I have enclosed the slides for you to take a look at, if you're so kind to.
Thank you,
Hi Omar
variables are used globally in SL not on a slide by slide basis. So if you start with a T/F variable that has a default of 'False' and you trigger it to True on say Slide 2 - it will remain in that True state for the rest of the project even if you 'reset the slide to initial state' when revisited. You have to trigger the variable back to false for it to be used again - hence Ashley's comment above to reset the variable.
On your first slide, I created a trigger, Adjust variable 'complete' to value 'true' when state of all 'your four ? marks are visited'. This changes the variable to true and the next button to enabled.
On your second slide I created a trigger, Adjust variable 'complete' to value 'false' when the timeline starts on Slide 2...this way your variable is ready for the next set of instructions to turn it to true on slide 2.
Always be careful of your trigger order as well.
See attached if this helps you
Hi Omar,
Looks like Wendy has you covered here (thanks Wendy!) but let us know if you need additional assistance or explanation.
Yes, you all have been a tremendous help and I think I'm starting to get the hang of these Variables!
Thank you all again.
Thank you Wendy! You're explanation and file have helped.
Hi Wendy
Is it possible to add this variable reset to the master slide? When I tried that it added a layer to the master slide which I think is complicating things....
Thanks!
Lucy
Hi Lucy,
If you're using the variable on a master slide, it would be resetting any slides that are using that master so it could become problematic.
Adding a trigger or similar to a master slide shouldn't automatically create a new slide master layer for you - so I'd also want to confirm that you're working on local project files as described here.
Hi Ashley
I realised I had copied/pasted the trigger from a slide to the master which appears to be what was causing the new layer to appear - when I created it directly it worked beautifully. However, as you suggested, my logic was flawed and it *did* create a problem so I've done the variable reset on each slide instead.
Thanks for the help!
Lucy
Sorry I missed your post Lucy...what Ashley said :-)
Thanks Lucy for the update and glad you were able to figure it out!
Hi Michael, a very good help. Just wondering here. with your setting, the next button will be disabled when we click previous button (revisiting the slide) any idea how to enable the next button when revisiting it?
I duplicate the slide to provide better understanding
Hi Ashley,
Really need a quick solution here, which I already posted my question earlier too. From Michael's answer, is there anyway I could enable the next button when click previous/revisiting the slide? duplicate the slide from Omar just for an example
You need a separate variable for each slide (in addition to "Complete") to indicate if this is the first visit to the slide. For example "Slide1Visited". When "Complete" is set to True, also set "Slide1Visited" to True.
Then add the condition "If Slide1Visited is equal to False" to the trigger that hides the Next button when the slide opens. When you return to the slide, the Next button will not be hidden.
This discussion is closed. You can start a new discussion or contact Articulate Support.