Trouble with Variables

Jul 15, 2020

Hi Everyone!

I am having some trouble with the variable functions, and I can’t seem to get past it.

Due to the nature of the project, I cannot link/share my course.


I am building out a course that will test learns on specific materials and then award them superpowers if they provide a correct answer. Through a lot of work, I have created a scorecard that will track all the superpowers that the learner has earned through the course. Learns can then click a scorecard button and see a lightbox of their current scorecard and all of their superpowers.

The Scorecard slide is contained in a separate scene along with other resource pages.

What I am trying to do

As the final activity in the lesson, I want learners to save the score screen to a PDF using the print screen function so that they can bring their scorecard with the tracked superpowers to a VILT. I have used some java code that I have attached to a capture button, and it works great.

Here is my issue: I don’t want learners to see the capture button until they get to the last slide, of course.

The problem

I have done a fair amount of research, and I am pretty sure I can accomplish this by the use of variables, states, and triggers. So I went about creating it by:

1.       I am making a white rectangle that sits over my button, effectively hiding it for the majority of the course.

2.       Setting a normal and disabled state for this white rectangle

3.       Setting a default state to normal

4.       Creating a variable called “End of course” with a default state of false

5.       Setting a trigger on my white rectangle to change its state from normal to disabled with the “End of Course” Variable changed from False to true

6.       On my final slide, I am adding a trigger to when the scorecard button has been selected to change the variable from false to true.

In the preview, this does not work, and the white rectangle remains regardless of state.

Things I have tried

1.       Using Reference function to ensure that the variable is changing. It does change at the appropriate time

2.       Ordered triggers to make sure variable change comes first

3.       Set trigger for variable change to timeline beginning

4.       Set trigger for variable change to timeline end

5.       Created a test button for a trigger for variable change

All of these affect the variable, but the variable is not affecting my rectangles state. I almost feel like I haven’t successfully attached the variable to my white rectangle, but to my eye, I have done everything I can.

I have copied the steps in the instructional videos precisely, with the only difference being the slides are in different scenes.

Any help, advice or alternate suggestions is appreciated


3 Replies
Dave Cox

Hi Robert,

I agree with Michael. You should change the state of the white rectangle to hidden. 

The reason for this is you have the rectangle over your button. Hidden is the only state what will allow you to click the button underneath it. In any other state, the rectangle is in the way, and you can't click the object underneath.

Better yet, why not remove the rectangle, and set the state of your button to disabled, or hidden? If you set the button to disabled, you won't be able to click it, and you can change the image state to show that is it disabled. If you change it to hidden, you still won't be able to click it, and you won't be able to see it either.


This discussion is closed. You can start a new discussion or contact Articulate Support.