Back out of alert

So I have an alert that pops up giving me two options to proceed. I was wondering if there was a way to back out of an alert if the user does not want to pursue either of those options? I feel like the most intuitive option is to be able to just tap the screen behind the alert but I haven’t been able to find a way to do that. Any ideas?

You could make a list alert and have one of the options as cancel. Check out docs on the Alert component for more info.

1 Like

So I used that method to instead have 3 different options for moving forward (it solved a huge problem I have been having)

But now as I am tying up loose ends, I still am wondering about a way to exit out of an alert so the user doesn’t have to move forward and can just go back to pre-alert. As of yet there isnt a “If screen click” control so I am not sure if there would be a way around it currently

Do you mean you are using an alert to check if user wants to progress to next “step”? If so, you can check if alert “was confirmed” pretty easy like this

No, so my alert has 3 options the user can pick to move to 3 different screens. But if someone accidentally clicked the value that triggers the alert, I was looking for a way they could back out instead of having to progress to the next screen and then go back

Ahhh… I see. Maybe a custom popup? I use quite often now just for the sake of more styling options

3 Likes

I’ll give that a shot, that could work well

You could definitely do this!

I would have a stored variable called lastscreen

Every time I navigate to a new screen I would update the lastscreen Variable with the name of the screen you’re navigating away from

When you click the back button it navigates to the variable lastscreen

@huntermclarkn

You could call a second default alert that says “Are you sure you want to proceed?”

You can also call two alerts at the same time and whichever one was called second will appear on top of the other alert.

When the user picks and option, set a variable to that option. Once the second chance alert is confirmed, navigate to a screen depending on the initial alerts value.

2 Likes

^^^

This is a good option!

“Are you sure you want to go to {$screenName}?”

“Yes/No”

1 Like