cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Borgy
Frequent Visitor

Push Notifications

Hi, we're using Power Automate to send push notifications to our users when some new content is available in one of our PowerApps. We're setting this via parameters that the PowerApp grabs on the OnStart event of the main application which then navigates to the appropriate screen. This works fine if the app is closed but if it's already open it does nothing. I understand why because the OnStart event isn't triggered. Any ideas on how to handle this? We'd obviously like it to navigate to the correct screen whether the app is open or closed.

 

Thanks

 

Borgy_0-1597027329014.png

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-siky-msft
Community Support
Community Support

Hi @UdayAdhikari ,

 

There is a mechanism by design that the parameter can only be passed when the App is being open, it has nothing to do with OnStart event.

Hence, if the app is open or suspended when you tap the notification, the parameters won't be passed into app.

If you want to enhance this function, please vote for this idea and submit your feedback.

Hope this helps.

Sik

View solution in original post

4 REPLIES 4
UdayAdhikari
Continued Contributor
Continued Contributor

Hi @Borgy - in that case, I would have created a separate Power Automate flow to monitor for new content (looks like you are using SharePoint so the trigger would be when a new item is created) and add push notification action. If you have some logic that you have in App OnStart then you can mirror the same in flow. I am guessing you have more to this 🙂 if so please add details and happy to help how I can.

 

Thanks

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

v-siky-msft
Community Support
Community Support

Hi @UdayAdhikari ,

 

There is a mechanism by design that the parameter can only be passed when the App is being open, it has nothing to do with OnStart event.

Hence, if the app is open or suspended when you tap the notification, the parameters won't be passed into app.

If you want to enhance this function, please vote for this idea and submit your feedback.

Hope this helps.

Sik

mj7
Helper I
Helper I

@Borgydid yo know how to do it? to click and pass to the screen that you want?? how you put your params?

Anonymous
Not applicable

I am trying to use the basic syntax of a Push Notification function as per below:
PowerAppsNotification.SendPushNotification(
    {
        recipients: [Push_notif_Push.Text],
        message: "A new customer remote support case has been created!"
    }
);
The "Push_notif_Push" is a TextInput field with the following 
 
Basically what we have as a result is "userx@email.com, usery@email.com, userz@email.com" which goes straight to "recipients" field under PushNotification function.

Capture.JPG

It just does not work and i cannot see any forum doing this deep dive into the syntax.. its just annoying! The error message is just another encrypted feedback which makes me believe that PowerApps is still not "designed" for non-programmers like me. If I need to invest hours googling information just to understand an error message... something is not in shape as originally designed.
Capture2.JPG

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Super User 2 - 2022 Congratulations

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (4,333)