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 / After loading Collecti...
Power Apps
Answered

After loading Collection, notification keeps coming?

(0) ShareShare
ReportReport
Posted on by 997

Hello,

No idea what i do wrong,

But the notification popup always even data has been found?
This one gives me an error
invalid argumenttype

 

ClearCollect(
 MySales;
 If(
 IsEmpty(
 Filter(
 OnlineData;
 (MonthValue = "FEBRUARY 2024")
 )
 );
 Notify("No Data."; NotificationType.Error);
 ForAll(
 GroupBy(
 AddColumns(
 Filter(
 OnlineData;
 (MonthValue = "FEBRUARY 2024")
 );
 "LogText";
 Last(Split(CODE; "-")).Value
 );
 "LogText";
 "MySales"
 );
 {
 LogText: ThisRecord.LogText;
 MySales: Text(
 Sum(ThisRecord.MySales; PRICE);
 "$#,###0.00"
 )
 }
 )


 )
)

 

This parts works... weird when i do 2x ;;

 

ClearCollect(
 MySales;
 If(
 IsEmpty(
 Filter(
 OnlineData;
 (MonthValue = "FEBRUARY 2024")
 )
 );;
 Notify("No Data."; NotificationType.Error);
 ForAll(

 

It works without error, but then the notification keeps popup instead only when no data has been found

What do i wrong?

Thank you



Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,963 Moderator on at

    Hi @TimmyBoy 

     

    I dont know if its just the copy / paste and code snippet issue, (so apologies if so), 

    but I see that you do not have a , (comma) for your if.

     

    Is it just replacing your commas with semi colons?


    If I have helped you, I would really appreciate if you please Mark my answer as Resolved/Answered, and give it a thumbs up, so it can help others

    Cheers

    Thank You
    Michael Gernaey MCT | MCSE | MCP | Self-Contractor| Ex-Microsoft
    https://gernaeysoftware.com
    LinkedIn: https://www.linkedin.com/in/michaelgernaey

  • Verified answer
    TimmyBoy Profile Picture
    997 on at

    Hello,

    Well seems this little trick worked
    Still not really a clue why it didn't work the previous way
    But, thanks all 😉

     

    ClearCollect(
     MySales;
     If(
     IsEmpty(
     Filter(
     OnlineData;
     (MonthValue = "FEBRUARY 2024")
     )
     );Set(yesdata;false);;
     Notify("No Data."; NotificationType.Error)
     ;
     Set(yesdata;true)
    
     )
    );;
    If(yesdata;
    ClearCollect(
     MySales;
    ForAll(
     GroupBy(
     AddColumns(
     Filter(
     OnlineData;
     (MonthValue = "FEBRUARY 2024")
     );
     "LogText";
     Last(Split(CODE; "-")).Value
     );
     "LogText";
     "MySales"
     );
     {
     LogText: ThisRecord.LogText;
     MySales: Text(
     Sum(ThisRecord.MySales; PRICE);
     "$#,###0.00"
     )
     }
     )
     )
    )

     

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 421

#2
WarrenBelz Profile Picture

WarrenBelz 345 Most Valuable Professional

#3
Kalathiya Profile Picture

Kalathiya 278 Super User 2026 Season 1

Last 30 days Overall leaderboard