Hi,
I am trying to write a method that when invoked, changes a boolean variable to true, and when invoked again, changes the same variable to false, etc.
For example: call method -> boolean = true -> call method -> boolean = false -> call method -> boolean = true
So basically,
if (a = false) { a = true; }
if (a = true) { a = false; }
I am not sure how to accomplish this, because every time I call the method, the boolean value changes to true and then false again.
Thanks.