web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Error in my Notificati...
Power Apps
Answered

Error in my Notification Message Pop-Ups

(0) ShareShare
ReportReport
Posted on by

Hi everyone! Currently creating a Power App in which a user can Nominate another user. I'm using a Combo Box to pick and select user and a SharePoint in which user can later be saved. Let's say a user wants to nominatee someone that has previously been nominated by somebody else, then a notification message should appear and let the user know that person X has been nominated in X category. Problem is, the code i have that does such function seems to work once app is published but after couple of hours its starts to show errors. Such as: even if a person did not be nominated in the sharepoint, once this same person is selected on Power Apps, the notification message appears even after closing the app. I changed the code so often and it seems to work at the beginning but after hours it shows errors, someone to give me some tips on how i can fix this?

 

ClearCollect(
 ExistingNominations,
 Filter(SharePoitList, Title = ComboBox1.Selected.Id && !IsBlank(NominationType))
);

//notification message based on the nominated categories
If(
 CountRows(ExistingNominations) > 0,
 Set(
 NotificationMessage,
 "This person has already been nominated " &
 If(
 CountRows(ExistingNominations) = 1,
 "in the " & First(ExistingNominations).NominationType & " category.",
 CountRows(ExistingNominations) = 2,
 "in the following categories: " & Concat(ExistingNominations, NominationType & " ", " and ") & ".",
 "in the following categories: " & Concat(ExistingNominations, NominationType & " ", ", ") & "and ."
 ) &
 " Instead, you can emphasize [BLANK]."
 )
 
 
);

Notify(
 NotificationMessage,
 NotificationType.Warning,
 60000
);

 

Categories:
I have the same question (0)
  • Verified answer
    Rajkumar_M Profile Picture
    3,747 Moderator on at

    It seems that the issue with your code is that the notification message is being stored in a variable called "NotificationMessage" and is not being cleared when the user selects a different person from the ComboBox. This means that if the user selects a person who has already been nominated, the notification message will still appear even if the user has closed and reopened the app. 

    ClearCollect( ExistingNominations,

    Filter(SharePoitList, Title = ComboBox1.Selected.Id && !IsBlank(NominationType)) ); //notification message based on the nominated categories

    If( CountRows(ExistingNominations) > 0, Set( NotificationMessage, "This person has already been nominated " &

    If( CountRows(ExistingNominations) = 1, "in the " &

    First(ExistingNominations).NominationType & " category.", CountRows(ExistingNominations) = 2, "in the following categories: " &

    Concat(ExistingNominations, NominationType & " ", " and ") & ".", "in the following categories: " & Concat(ExistingNominations, NominationType & " ", ", ") & "and ." ) & " Instead, you can emphasize [BLANK]." ), Set(NotificationMessage, "") ); Notify( NotificationMessage, NotificationType.Warning, 60000 )

    Thanks!

    If my response has been helpful in resolving your issue, I kindly request that you consider clicking "Accept as solution" and "giving it a thumbs up" as a token of appreciation.

  • esilvac Profile Picture
    on at

    Thank you so much! Any tips on how I could clear NotificationMessage afterwards?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 633

#2
11manish Profile Picture

11manish 588

#3
Valantis Profile Picture

Valantis 457

Last 30 days Overall leaderboard