Increment boolean should cycle between 1 and 0

I have a field set to boolean, and when I click an item in a list, I want it to cycle between on and off. I select the action “add one to this number”, because a bit, if you shift it, cycles between 1 and 0. But not in Glide. I cannot simply set action to “set column values” and set it to true, because there is no “if, then, else” in set column values.

Hola @dgabler13

Inside the action builder you can have a condition:

If a is true > set column value > false

else > set column value > true

1 Like

Thank you. Everything about Glide is more complex than a programming language, where you have granular control of every field and every variable at will. I never could get a handle on the Lego Mindstorms visual object programming language. There was no “flow” to it.

Interesting idea!

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.