|
1 | 1 | ---
|
2 |
| -title: Send a push notification | Microsoft Docs |
3 |
| -description: Learn how to send native push notifications to an app in Power Apps. |
| 2 | +title: Send a push notification from a canvas app. | Microsoft Docs |
| 3 | +description: Learn how to send push notifications from a canvas app in Power Apps. |
4 | 4 | author: kavishi
|
5 | 5 | ms.service: powerapps
|
6 | 6 | ms.topic: conceptual
|
7 | 7 | ms.custom: canvas
|
8 | 8 | ms.reviewer: tapanm
|
9 |
| -ms.date: 08/20/2020 |
| 9 | +ms.date: 10/23/2020 |
10 | 10 | ms.author: kaagar
|
11 | 11 | search.audienceType:
|
12 | 12 | - maker
|
13 | 13 | search.app:
|
14 | 14 | - PowerApps
|
15 | 15 | ---
|
16 |
| -# Send a push notification in Power Apps |
| 16 | +# Send notification from an app |
17 | 17 |
|
18 |
| -Push notifications are used in mobile apps to engage app users and help them prioritize key tasks. In Power Apps, you can send notifications by using the Power Apps Notification connector. You can send native push notifications to any app that you create in Power Apps. |
| 18 | +You can send a push notification from one app to another or to the same app. In canvas apps, you can send notifications by using the Power Apps Notification connector. |
19 | 19 |
|
20 |
| -## Send a notification from an app |
21 |
| -You can send a push notification from one app to another or to the same app. |
| 20 | +In this article, the sample app used for notifications is built from the default **Case Management** app template. |
22 | 21 |
|
23 | 22 | 1. In [Power Apps](https://make.powerapps.com?utm_source=padocs&utm_medium=linkinadoc&utm_campaign=referralsfromdoc), go to the app to which you want to send push notifications.
|
24 |
| -2. On the **Details** tab, copy the **App ID** of that app. |
25 | 23 |
|
26 |
| -  |
27 |
| -3. On the **Connections** tab, create a connection to the Power Apps Notification connector, and paste in the app ID from the previous step. |
| 24 | +1. Copy the app ID. More information: [Get an app ID](get-sessionid.md#get-an-app-id) |
28 | 25 |
|
29 |
| -  |
30 |
| -4. Add the connection to the trigger app. |
| 26 | +1. In the left pane, select **Data** - **Connections**. |
| 27 | + |
| 28 | +1. Edit the app that you want to send the notifications from. More information: [Edit an app](edit-app.md) |
| 29 | + |
| 30 | +1. Select **View** - **Data sources**. |
| 31 | + |
| 32 | +1. Select **Add data source**. |
| 33 | + |
| 34 | +1. Select **New Connection**. |
| 35 | + |
| 36 | +1. Select **Power Apps Notification**. |
| 37 | + |
| 38 | +  |
| 39 | + |
| 40 | +1. Paste the app ID copied from the previous step. |
| 41 | + |
| 42 | +  |
| 43 | + |
| 44 | +1. Select **Connect**. |
| 45 | + |
| 46 | +1. Add the connection to the trigger app. |
31 | 47 |
|
32 | 48 | In our example, we use the same app as the trigger app. The user who reassigns the case also triggers a push notification to the new case owner.
|
33 | 49 |
|
34 | 50 | 
|
| 51 | + |
| 52 | +1. In [Power Automate](https://flow.microsoft.com), create a trigger that specifies when the push notification is sent. |
| 53 | + |
| 54 | + |
| 55 | + |
35 | 56 | 5. From the push notification connection, call the **SendPushNotification** method.
|
36 | 57 |
|
37 | 58 | In our example, we trigger this notification by using the **OnSuccess** property in a form.
|
38 | 59 |
|
39 | 60 | 
|
40 | 61 |
|
41 | 62 | ## Load a specific page and context when a user taps the notification
|
| 63 | + |
42 | 64 | ### Pass parameters
|
| 65 | + |
43 | 66 | Your push notification can pass specific parameters to the app. For example, to read the **CaseID** value, use *Param("CaseID")*. To quickly identify this parameter, add a **Label** control to your app. Set the **Text** property of that control to **Param("CaseID")**. If the user opens the app from the **All apps** list, the value is empty. If the user opens the app from another ___location on the device, the value is populated with the **CaseID** value.
|
44 | 67 |
|
45 | 68 | ### Set the start page
|
| 69 | + |
46 | 70 | You can set your app to open, for example, the **Case details** page as soon as the app opens:
|
47 | 71 |
|
48 | 72 | 1. Add a **Timer** control, and set its **OnTimerEnd** property to this formula:
|
@@ -97,10 +121,10 @@ PowerAppsNotification.SendPushNotification(
|
97 | 121 | ```
|
98 | 122 |
|
99 | 123 | ## Known limitations
|
| 124 | + |
100 | 125 | * Currently, notifications aren't displayed on Power Apps Mobile for Windows Phone.
|
101 | 126 | * Currently, we don't provide push notifications for users who run apps only in a web browser.
|
102 | 127 | * Notifications show the generic Power Apps icon instead of a specific app icon.
|
103 | 128 | * Push notifications aren't currently supported for Model Driven apps.
|
104 | 129 |
|
105 | 130 | For reference information, see [Power Apps Notification reference](https://docs.microsoft.com/connectors/powerappsnotification/).
|
106 |
| - |
|
0 commit comments