True/False variables in ActivePresenter 9 can return both true or false values. They can be utilized to trace issues which can be proper or mistaken, on or off, clicked or not clicked, and even management two states of an object, for instance, a toggle button.
The True/False variable is among the three variable varieties that ActivePresenter 9 gives. On this tutorial, you’ll discover ways to use it as a situation to manage the 2 states of a toggle button like this:
This tutorial covers:
- Design the Two States of the Toggle Button
- Create a True/False Variable
- Assign Actions to Alter the Variable
Design the Two States of the Toggle Button
A toggle button consists of two states, on and off. You put together a picture because the ‘on’ state then entry the View tab > Object States so as to add the opposite ‘off’ state to it.
To be taught extra concerning the Object States in ActivePresenter 9, confer with this tutorial.
Create a True/False Variable
Should you click on on the toggle button, the 2 states will present up in flip. For that to occur, it is advisable to use a real/false variable and alter its worth to true or false for every state every time the toggle button is clicked.
To create a real/false variable, you navigate to the House tab, then click on on Variables.
Within the dialog that seems, click on on the inexperienced plus button on the backside so as to add a brand new variable, choose the TRUE/FALSE sort, and outline its preliminary worth if any. Then, click on Add & Shut to complete.
Assign Actions to Alter the Variable
Now add actions to change between the 2 states of the toggle button.
Firstly, you choose the button and navigate to its Properties pane > Interactivity > Occasions – Actions. Then add the On Click on occasion and the Alter Variable motion. To allow the toggle operate, you choose the true/false variable created earlier from the record and the Toggle operator.
After that, you add the Change Object State actions and circumstances corresponding to every state as follows:
For the reason that preliminary worth of the variable is True, so it is best to assign it to the default ‘on’ state. And assign the ‘false’ worth to the opposite state.
For extra details about occasions and actions, see Use Occasions-Actions to Add Interactivity to Programs.
That’s it! You’ve gotten realized about how you can use the True/False variable to make a toggle button. Hopefully, this tutorial might be useful for you. Please be happy to obtain ActivePresenter 9 and check out it out!
See additionally: