# Safety "Do you really want to ...?" conditional

**URL:** <https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416>\
**Category:** Ask for Help\
**Created:** [March 17, 2021, 9:20pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416 "2021-03-17T21:20:29Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![forsdick](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/forsdick/32/26296_2.png) [@forsdick](https://community.glideapps.com/u/forsdick)\
**Post date:** [March 17, 2021, 9:20pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/1 "2021-03-17T21:20:29Z")

</div>

I want to ensure that the user really wants to delete an item in a list by asking the question “Do you really want to delete this item?” and then either proceed if the user clicks a positive response or do not delete the item and leave the user where s/he was before clicking on the delete button.

I tried to see if there was anything in the action operations that I could do to create a “careful delete row”, but couldn’t fine anything to build this action.

Any ideas?

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [March 17, 2021, 9:25pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/2 "2021-03-17T21:25:53Z")

</div>

You could try to set an action to link to screen ‘this Item’ to get a new screen. Then have your, ‘are you sure’ and another delete button that does the actual delete and a go back.

---

<div class="post-metadata">

**Author:** ![V88](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/v88/32/90054_2.png) [@V88](https://community.glideapps.com/u/V88)\
**Post date:** [March 17, 2021, 9:43pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/3 "2021-03-17T21:43:41Z")

</div>

I have done this previously using a switch with caption “Delete this item” which then enables a button and even a hint. It works quite well.

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [March 17, 2021, 11:31pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/4 "2021-03-17T23:31:37Z")

</div>

+1 for this approach. On the final screen I add a bar button, one to go back, one to actually delete (and go back one more time to the original screen with the list of items, adding to the native go back by the delete action).

---

<div class="post-metadata">

**Author:** ![Robert\_Petitto](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/robert_petitto/32/25193_2.png) [@Robert\_Petitto](https://community.glideapps.com/u/Robert_Petitto)\
**Post date:** [March 17, 2021, 11:39pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/5 "2021-03-17T23:39:22Z")

</div>

I often use a “delete” button that hides itself and then shows a button bar with

1. a “confirm” that actually deletes the item and
2. a “cancel” button that brings back the “delete” button

---

<div class="post-metadata">

**Author:** ![Rosewebstudio](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/rosewebstudio/32/12261_2.png) [@Rosewebstudio](https://community.glideapps.com/u/Rosewebstudio)\
**Post date:** [March 18, 2021, 5:21am UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/6 "2021-03-18T05:21:28Z")

</div>

I did this

Button - Delete

Then set an action on this delete button which increments a field by 1.

If increment is 1 hide delete button

Then show button bar and warning text if increment is 1

Delete button then has an action to delete  
Cancel button resets increment so it’s no longer 1

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/a/8/a897a14fce88dc747cef7eb900f1d738d92d324e.gif)

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [March 18, 2021, 5:36am UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/7 "2021-03-18T05:36:54Z")

</div>

Very nice, Jason 👍

---

<div class="post-metadata">

**Author:** ![forsdick](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/forsdick/32/26296_2.png) [@forsdick](https://community.glideapps.com/u/forsdick)\
**Post date:** [March 18, 2021, 1:46pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/8 "2021-03-18T13:46:37Z")

</div>

And, to be consistent in my desire to see easy solutions to common requirements prevalent in Glide, I think “careful delete” is a very important feature to encourage in all apps. Glide should provide a standard way to do this: not that it is the only way, but for newbies (and lazy people like me 🙂 ) is very useful.

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [March 18, 2021, 2:06pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/9 "2021-03-18T14:06:03Z")

</div>

Doesn’t the native Delete through the edit mode already ask for confirmation? I’m guessing if you are instead doing it through an action, you should know that you want something to be deleted blindly and in a lot of cases, you may not want a confirmation if it’s a backend action. If you want different results, then you should “program” for it accordingly. Are you saying that every single time the Delete Action is fired, that an automatic confirmation should pop up, or would it be optional depending on the circumstances of the delete? Just my thoughts on trying to cover every single possible scenario.

---

<div class="post-metadata">

**Author:** ![Shmuel\_Munitz](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/shmuel_munitz/32/31720_2.png) [@Shmuel\_Munitz](https://community.glideapps.com/u/Shmuel_Munitz)\
**Post date:** [September 14, 2021, 2:51am UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/10 "2021-09-14T02:51:01Z")

</div>

How dio you do those “If this” “Then That” I don’t see such option in the increment fields?

---

<div class="post-metadata">

**Author:** ![Rosewebstudio](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/rosewebstudio/32/12261_2.png) [@Rosewebstudio](https://community.glideapps.com/u/Rosewebstudio)\
**Post date:** [September 14, 2021, 3:24am UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/11 "2021-09-14T03:24:17Z")

</div>

Welcome to the community 👋

It’s a ‘visibility’ condition on the button component.

A simple example

**Button x**

- Show Button x if increment field _‘is empty’_

**Button y**

- Show Button y if increment field _= ‘1’_

> **[Component Visibility](https://docs.glideapps.com/all/reference/conditions/component-visibility)**

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/3/9/39fd1b31d952c8dda07e92861c7bbc4686014b72.gif)

---

<div class="post-metadata">

**Author:** ![Roberto\_Lopes](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/roberto_lopes/32/66552_2.png) [@Roberto\_Lopes](https://community.glideapps.com/u/Roberto_Lopes)\
**Post date:** [November 16, 2023, 4:43pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/12 "2023-11-16T16:43:39Z")

</div>

It’s shameful for a system like this to not have a simple confirmation action. primary errors.

---

<div class="post-metadata">

**Author:** ![NoCodeAndy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nocodeandy/32/62530_2.png) [@NoCodeAndy](https://community.glideapps.com/u/NoCodeAndy)\
**Post date:** [January 17, 2024, 4:49pm UTC](https://community.glideapps.com/t/safety-do-you-really-want-to-conditional/24416/13 "2024-01-17T16:49:08Z")

</div>


