Build in-app notification for model driven apps

Build in-app notification for model driven apps

For this week, I want to explore the possibility of building in-app notification for a model driven app.

But how?

We don't need to write some fancy code to do this but rather use XrmToolBox (Home?· XrmToolBox). This is a prerequisite to use the In-App notification builder tool. You can install this tool from the tool library in XrmToolBox.

Now that you have the tool installed, it is important to configure connection to your environment.

No alt text provided for this image

Once you have connected to your environment, we can go ahead and open the in-app notification tool. And from the app drop down we can select the app where we want to implement notification.

No alt text provided for this image

I want to implement the notification for Asset management app in the current environment. As we haven't created any notification before this app, we see a red button next to the 'Notification Status'.

No alt text provided for this image

We are going to go ahead and click the red button to enable the in-app notification for this app.

No alt text provided for this image

And what now?

Now let's start building the custom notification. Within the data tab you can change a lot of things like the title and body of the notification. You can also add hyperlinks/images to the body.

With the toast type we can either select timed or hidden, the first being a pop-up notification and the latter being a hidden notification.

No alt text provided for this image

On the right side, you see the preview of your in-app notification button. Here I want it as an info notification, but you can also change it to failure/success/warning or even add a custom icon (web resource) for your own custom notification.

After filling in the data tab, we now move on to the action tab. I go ahead create a new action type for Record.

No alt text provided for this image

Here you see that the id is weird it only has 0s. But you want the id to be dynamic based on the record that you have created. And this is where the magic happens. Once you are satisfied with your actions. Let us go and hit the get code button. We select the option of Power Automate as we want to use it in a flow and get dynamic values of the record (id).

No alt text provided for this image

Let's make a flow now and use the get code snippets in that. I want to trigger a flow when a new record is created in the asset table.

No alt text provided for this image


And to enable the in-app notification, I am going to add the action "add a new row" and use the notifications table. And when you click the advanced options in the action, you notice that some of the fields are the same as the get code button. So, go ahead and copy the values from XrmToolBox to the respective fields in Power Automate.

No alt text provided for this image

As I mentioned earlier, we want to add context to the notification. So, we go ahead and replace the highlighted value with dynamic content (guid) from the previous step.

Let's Test it

I will go ahead and create a new asset.

No alt text provided for this image

And once I hit the save button, we are going to trigger the flow, and it seems like the flow run was a success.

No alt text provided for this image

And voila! We got out in-app notification.

No alt text provided for this image

Because we have attached the guid of the asset we can go ahead and click the "A new Asset" button, and this should open the related record.

No alt text provided for this image

That is super cool.


Miguel Verweij

Powerbouwer | Microsoft Business Applications MVP | PowerAddictsNL | Power Platform Challenge

2 年

Nice stuff mate! Keeep up the good work ??

要查看或添加评论,请登录

Ashwin Ganesh Kumar的更多文章

  • Bulk Deletion in Dataverse: A Beginner's Guide

    Bulk Deletion in Dataverse: A Beginner's Guide

    We recently encountered a challenge with Dataverse capacity on the client side. One way to overcome this issue is to…

  • Column-Level Security- What is that?

    Column-Level Security- What is that?

    If you are new to working on projects with Dataverse, this could be a bit overwhelming. But don't worry, we will figure…

    11 条评论
  • Patching different Dataverse column types in Power Apps (Canvas Apps)

    Patching different Dataverse column types in Power Apps (Canvas Apps)

    In this article, I want to explore PATCH function in Power Apps. The focus is to show you how we can use this function…

    1 条评论
  • Power Apps Monitor

    Power Apps Monitor

    Have you encountered a situation where the app that you have developed is slow or has some issues? Or have you been in…

    1 条评论
  • Virtual Table Creation Wizard

    Virtual Table Creation Wizard

    What are virtual tables? It is a custom table in Microsoft Dataverse that contains data from an external data source…

    1 条评论
  • Review: CoE Starter Kit December release

    Review: CoE Starter Kit December release

    I think a lot of us have already installed CoE Starter Kit and are using it daily for different purposes like admin…

    2 条评论
  • Review: Security Risk Assessment and Management

    Review: Security Risk Assessment and Management

    I recently came across a LinkedIn post about Security Risk assessment app. As I haven't tried the previous version of…

    4 条评论
  • Review: Power Platform Adoption Assessment

    Review: Power Platform Adoption Assessment

    What is it? It is a tool to help customers run through a set of questions based on their interests. The tool then gives…

    5 条评论

社区洞察

其他会员也浏览了