how to increment the value in a variable

James Rivera shared this question 7 years ago

I have a variable set to a default value of 2, and when I click a check button I want to subtract 1 from the variable and set it to a value of the result (1 or 0). On the reverse, when I clear the checkbox I want to add to the variable

Comments (1)


You can use the 'set value' action that changes the value on the variable, and then, in the calculated value, create an expression like this: variable + 1. Then create another action alike but with variable-1. Then add conditions to both actions so they trigger only when the checkbox is checked or otherwise.