Take Value from RG with Toggle

I have created a “New User” window for Admins to easily add people to the system, but each user might be assigned to one or more specific locations, as shown below.

The locations are an RG from a [Locations] database (this is necessery for the rest of the app), so I have added a toggle to say whether or not the new person is to be assigned to that specific location.

My question is how can I add the locations to the workflow?

I need to point it to the correct row in the RG, and check to see if the toggle is “yes” before adding it to the list of texts. Any ideas?

Also, I need to make sure at least one has been selected.

Create a location custom state (set it to be a list if you want more than 1 entries).

When a group/text of the current cell is clicked, add the current cell’s value to that custom state.

When you create the user, simply reference to the location custom state.

Add a condition to check for the number of items in the custom state list

Hope this helps

1 Like

Thank you. This worked, but I don’t really understand why just yet.

I think no code is brilliant, but this seems to be an example of when no code is actually more complicated than just using logic :joy: