How To Create A Popup Message Or Alert Box In PowerApps (2023)

  • 47.1k
  • 0
  • 4
(Video) How to create a popup or alert box in PowerApps

While developing a canvas app many times we come across a scenario to create a popup message or an alert box. In this article, we will see how to create a popup confirmation message to delete an item from a gallery.

I have used a standard gallery with a delete button. When a user clicks on a delete button, an alert message should pop up asking for confirmation. If he clicks on "Yes" an item will be deleted and if he clicks on "No" the popup will be hidden and no action will be performed on that item.

(Video) How to create a pop-up message in PowerApps

Below is my typical horizontal gallery where you can see a delete button to delete the particular record:

How To Create A Popup Message Or Alert Box In PowerApps (3)

To create a popup in PowerApps, we will use a group of controls likerectangles, labels, and buttons. We will set a visible property of this group with one variable. This will allow us to show and hide the popup based on variable value.

Step 1 -Set a variable named varShowPopup on click on the delete button

How To Create A Popup Message Or Alert Box In PowerApps (4)

Step 2 -Add different controls to create a popup on the screen

  1. Add a full-screen rectangle and change the color opacity to 0.5 as shown below. This will make the rectangle transparent.

    (Video) Dialog box in PowerApps | Pop up | Confirmation Box | Message Box | Window

    How To Create A Popup Message Or Alert Box In PowerApps (5)

  2. Add another white color rectangle,labels for popup heading and message, close button,savebutton and make a group of these controls as shown below,

    How To Create A Popup Message Or Alert Box In PowerApps (6)

  3. Set the visible property of this group to "varShowPopup". This is the same variable that we have initialized in Step 1.

    (Video) Create Custom Dialog and Message Boxes in your Microsoft Power Apps

    How To Create A Popup Message Or Alert Box In PowerApps (7)

  4. Set the variable to false, so that a popup will be hidden on the click on the close button.

    How To Create A Popup Message Or Alert Box In PowerApps (8)

  5. Similarly for the delete button, write whatever formula you want to perform on click on the delete button, and at the last set varShowPopup variable to false so that the popup will be hidden. In this case, I am writing the remove function to delete the selected record and at the end, I am setting the variable to false.

    (Video) PowerApps are you sure popup | PowerApps popup message | powerapps tutorial | powerapps back button

    How To Create A Popup Message Or Alert Box In PowerApps (9)

Final Output

How To Create A Popup Message Or Alert Box In PowerApps (10)


Videos

1. How to Create a Dialog Box or Popup in Canvas PowerApps
(Ramprakash Duraisamy)
2. Power Apps - How to Create a Dialog Box in 3 Steps
(April Dunnam)
3. Create Reusable Confirmation Pop Up in Power Apps
(Dhruvin Shah)
4. PowerApps - Modal Dialog Form Tutorial
(Kumo Partners)
5. Confirmation Popups Screens in PowerApps
(Pragmatic Works)
6. How to Create a Pop-Up Window and Remove a Record | Microsoft PowerApps | 2022 Tutorial
(Michael Alex)
Top Articles
Latest Posts
Article information

Author: Stevie Stamm

Last Updated: 12/17/2022

Views: 5788

Rating: 5 / 5 (80 voted)

Reviews: 87% of readers found this page helpful

Author information

Name: Stevie Stamm

Birthday: 1996-06-22

Address: Apt. 419 4200 Sipes Estate, East Delmerview, WY 05617

Phone: +342332224300

Job: Future Advertising Analyst

Hobby: Leather crafting, Puzzles, Leather crafting, scrapbook, Urban exploration, Cabaret, Skateboarding

Introduction: My name is Stevie Stamm, I am a colorful, sparkling, splendid, vast, open, hilarious, tender person who loves writing and wants to share my knowledge and understanding with you.