When the down arrow icon is clicked, then group answer shows. When the up arrow icon is clicked, the group answer collapses.
I’m trying to set a custom state that when the second down arrow icon is clicked while the first arrow icon is still open (group answer is visible), it should automatically collapse the first group answer and open the second group answer. How do i achieve that? Is this possible with the toggle action or I need to use the show/hide action?
Are you using a repeating group?
You will use custom state and instead of action to collapse/show, you will use conditionnal.
If you are using a RG, the state should be on the RG level and when user click arrow, you will update this state with Current cell (state will be of the type of the data source for RG).
And the group that collapse will have conditionnal to be visible when RG state = Current cell
WF will be on click arrow, set state RG = Current cell
If you don’t use a RG, you can give a different name to each group that collapse and set a different text value for each of them. State will be text and conditionnal will be State = text value you want
Yes, I am using a repeating group. My data source is set to All Options since I’m using option sets. This makes it a bit difficult for me to use the logic especially since I’m using the toggle action instead of the show/hide action.
Would you mind setting up the custom states then I can learn from what you’ve set up and see how it flows, I believe I can have a better understanding that way.
I’ve updated your page
You need two WF
One that check if the state = to current cell. If yes, clear the state
One that will check if state != current cell. If yes, set state = current cell