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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Apps
Unanswered

Workaround for the message

(6) ShareShare
ReportReport
Posted on by

TL;DR: If you see this error (similar for the And function), this is a spurious message that should not be displayed. The message does not affect the app runtime - it should still be working as before. To remove this message, please use this expression in the new App.OnError property to suppress it:

 

 

Error(Filter(AllErrors, Not (": Canceled" in Message), Not IsBlank(Message)))

 

 

More details: In a recent release (version 3.21122) we made a change so that errors that are not handled by the app would start being shown to the user. The idea was to make it more explicit when bad things happen in the app. However, one of those errors that are being shown are not caused by the app itself, but by an optimization made by the platform, and should not be displayed to the user.

 

This is one scenario where this can happen: a label has a Text property set to the following expression:

 

 

If(
 Or(
 LookUp(MyTable, Name = TextInput1.Text, IsActive),
 LookUp(MyOtherTable, Name = TextInput1.Text, IsActive)),
 "The record is active",
 "The record is inactive")

 

 

When there is a change in TextInput1, the rule will be re-evaluated, and if the LookUp can be delegated, a pair of network calls is made to retrieve the corresponding IsActive properties. If, before the call is completed, the value of the TextInput1 is changed again, the platform cancels the pending network calls (since their result would be stale), and starts new requests to retrieve the values of the IsActive property again.

 

When the LookUp calls are cancelled, the Or function will receive that cancellation, and it is treating it as an error (because it could not complete its calculation). The error is then bubbled up via the If function, and since it is not handled by the app, the message is shown to the user. When the network responses for the new LookUp calls arrive, the label value will be updated to what it was supposed to be, and the app continues working as it should. But the user will see the message that they shouldn't.

 

We are making a change to stop treating cancellation as errors (because they are not), but it will take a few weeks for the change to reach all regions. Meanwhile, we can use the new App.OnError property to "trap" those spurious cancellation errors so that they don't bubble up to the user. A way to do that is to filter the errors that are passed to it, removing those that are of this type. The expression below should take care of it:

 

 

Error(Filter(AllErrors, Not (": Canceled" in Message), Not IsBlank(Message)))

 

 

Hopefully this will help until the fix is properly deployed worldwide.

Categories:
I have the same question (0)
  • virakones Profile Picture
    389 on at

    Thank you for the workaround - this will give our users some peace of mind til fully resolved.

  • timl Profile Picture
    36,393 Super User 2025 Season 2 on at

    @CarlosFigueira - Many thanks for this excellent explaination and for the interim fix.

  • JR-BejeweledOne Profile Picture
    5,836 Moderator on at

    I followed this and now am getting an Invalid argument type Message.

  • cleve Profile Picture
    88 on at

    @CarlosFigueira Thank you for the workaround. There is an extra parenthesis in your solution. 

    Error(Filter(AllErrors, Not ": Canceled" in Message))

     

  • murphydm Profile Picture
    41 on at

    I've been seeing this in some of the SharePoint Forms I developed for my agency, these don't seem to have an App.OnError property that I'm aware of. Is there a similar solution that I can apply to my forms while we wait for a real fix? I tried If(!(": Canceled" in SharePointForm.Error),Notify(SharePointForm_1.Error,NotificationType.Error)) in onFailure but that doesn't have any impact on this.

  • CarlosFigueira Profile Picture
    on at

    @cleve thank you, updated it

  • CarlosFigueira Profile Picture
    on at

    @murphydm you should be able to find the OnError property of the App object as shown below:

    AppOnErrorOnSharePointForms.gif

    If you cannot find that property, can you let me know what version are you running? You should be able to find it at the Settings menu on top, then selecting Support and 'Session details'

  • murphydm Profile Picture
    41 on at

    Haha jeez, embarrassing, I'm not sure if I knew that App was clickable until you told me. Thank you!

  • james_hathaway Profile Picture
    427 on at

    Thanks @CarlosFigueira ,

     

    Very Useful workaround at least allows me to publish new App versions....

     

    So, I've just done an update to one of our Clients Apps, and I included the workaround to catch both the DIV/0 errors and the Or/And "Cancelled" errors.... but any idea what I use to catch the following error given to the Users?

    james_hathaway_0-1643294716213.png ??

     

    The Monitor is telling me its a "RegEx Error", with no further detail, but that actually kind of makes sense, as there's a Value(Text) formula in the App that tries to convert a "Currency Formatted String" into a numerical value (i.e. "£2.55" -> 2.55), - no doubt the code behind the PowerApps abstraction layer would use Regular Expressions to parse the text so that it can convert decimal and thousand separators, % symbols etc, depending on language/locale settings...

     

    I have heard that there is currently a known RegEx error in the Value function, and that a fix is working it's way through, so I'm not going to open that can of worms.... but I guess question for here is:

     

    How would we catch "RegEx Errors" in the App.OnError property to stop them bubbling up to the Users?

     

    Thanks!

     

    James.

     

  • Community Power Platform Member Profile Picture
    on at

    Hi @CarlosFigueira @james_hathaway ,
    Any updates on this ?

    Regards,
    Haripriya

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard