Simple Variable

sgroom
Community Member Posts: 13 ♪ Opening Act ♪
Hi there, I am new to using variables but need one to achieve a desired effect.
Basically, I have three tabs of information on a page that I would like learners to click. Once they clicked and read all three, I want a text box to appear with further information - not until all three tabs (buttons) have been clicked though.
I've looked on line and seen variables for something similar (activating a next button etc) but not explained in a way that I can do it step by step.
Could anyone help please?
Thanks for reading.
Basically, I have three tabs of information on a page that I would like learners to click. Once they clicked and read all three, I want a text box to appear with further information - not until all three tabs (buttons) have been clicked though.
I've looked on line and seen variables for something similar (activating a next button etc) but not explained in a way that I can do it step by step.
Could anyone help please?
Thanks for reading.
Comments
-
Use the variable manager to create a variable:
Name: buttons_clicked (You can choose another name if you like)
Initial value: 0
Add an action to each of your buttons:
1. First Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: a
Now the variable will contain "a" if the first button has been clicked.
2. Second Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: b
Now the variable will contain "b" if the second button has been clicked.
3. Third Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: c
Now the variable will contain "c" if the third button has been clicked.
Add another action to each button.
On: Click
Action: Show
Target: Additional_Texfield
Condition:
Only if ("All conditions must but true")
buttons_clicked Contains a
buttons_clicked Contains b
buttons_clicked Contains c
Add an action on page level:
On: Show
Action: Modify variable
Target: buttons_clicked
Type: Set as empty
Only to reset the variable
Tim -
Steve,
Another consideration especially if your using SCORM 1.2 and counting precious character space (SCORM 1.2 has a 4k limit is to add a condition to each of the actions on the buttons.
For example on the first button:
1. First Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: a
Condition:Variable=
Relationship= Does Not Contain
Value=a ***Please note the a changes to b for the next button, ect***
If you don't do the condition, a learner can basically click all three buttons repeatedly and the LMS would store each of those button clicks and eventually run out of space.
Hopefully this helps and makes sense
-kelly
@timk 61646 wrote:Use the variable manager to create a variable:
Name: buttons_clicked (You can choose another name if you like)
Initial value: 0
Add an action to each of your buttons:
1. First Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: a
Now the variable will contain "a" if the first button has been clicked.
2. Second Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: b
Now the variable will contain "b" if the second button has been clicked.
3. Third Button
On: Click
Action: Modify variable
Target: buttons_clicked
Type: Add to variable
Value: c
Now the variable will contain "c" if the third button has been clicked.
Add another action to each button.
On: Click
Action: Show
Target: Additional_Texfield
Condition:
Only if ("All conditions must but true")
buttons_clicked Contains a
buttons_clicked Contains b
buttons_clicked Contains c
Add an action on page level:
On: Show
Action: Modify variable
Target: buttons_clicked
Type: Set as empty
Only to reset the variable
Tim
Categories
- 35.9K All Categories
- 109 ✫ Announcements
- 33.1K Lectora®
- 31.1K Lectora Discussions
- 29K Lectora Desktop
- 2K Lectora Online
- 2K Lectora Feature Requests
- 71 Lectora User Groups
- 36 Lectora Accessibility User Group (LAUG)
- 25 ELB Learning Content
- 25 ELB Learning Content Discussions
- 329 CenarioVR®
- 196 CenarioVR Discussions
- 133 CenarioVR Feature Requests
- 42 Rockstar Learning Platform®
- 39 Rockstar Learning Platform Discussions
- 108 CourseMill®
- 108 CourseMill Discussions
- 47 ReviewLink®
- 47 ReviewLink Discussions
- 7 The Training Arcade®
- 7 The Training Arcade Discussions
- 936 All Things eLearning
- 37 eLearning Development
- 546 Learning Management System (LMS) Integration
- 333 Web Accessibility
- 1.2K ♪ The Green Room
- 9 Additional Learning Products