How to disable one button when two other buttons are selected?

Jul 06, 2023

Hi all,

I have three buttons (A, B, C). I want the user to be able to only select two of them at a time. That is, if they have chosen two buttons (A & C) the third (B) is disabled and then if they want to change their choice they must first deselect one button (A or C) to be able to select the (otherwise disabled, B) button. Hope this makes sense.

I just can't work out the best way for this to work with triggers. 

Many thanks,

Kevin

3 Replies
Phil Mayor

Going to need a few triggers to do it, I can think of a few ways not sure which is the simplest.

You could show a layer that is shown each time you press a button and then do a count of how many are selected and if equal to 2 disable the button that was not equal to selected.

Or you could add triggers if

A+B = selected disable C

A+C = selected disable B

B + C = selected disable A

You then need triggers to change back to normal and the layer option is probably better here as you can use the count to change any disabled back to normal