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 Platform Community / Forums / Power Apps / On Success for Patch
Power Apps
Answered

On Success for Patch

(0) ShareShare
ReportReport
Posted on by 123

Hello,

 

I understand the OnSuccess of a form does not work if the Patch() function is used to submit the form. I would like to notify the user if the form is submitted successfully even when using patch. How can I check this and notify with their result? 

 

Here is the patch in my Onsubmit 

CamCov_0-1652283484300.png

(Just looks up title to see if project already exists or not)

 

I would like to navigate(successSceen) when submission is successful or display error message if not without leaving the screen.

 

 

Categories:
I have the same question (0)
  • CU-18081211-6 Profile Picture
    9,270 Moderator on at

    @CamCov ,

    Here is an example it can inspire you:

    Set(varRecord, Patch(your_code_here));
    If(!IsBlank(varRecord),
     Notify("Your request has been succesfully submitted!", Notification.Success),
     Notify("Your request was not submitted", Notification.Failure)
    );

    Hope it helps !

  • Verified answer
    Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @CamCov 

    To be a bit more informative, use the Errors() function after the patch:

     

     

    Patch('Project Excellence'...);
    If( // check for errors
     !IsEmpty(
     Errors('Project Excellence'
     )
     ), // if true, show any error messages
     Notify( 
     Concat(
     Errors(
     'Project Excellence'
     ), Column & ": " & Message
     ), NotificationType.Error
     ),
     Notify(
     "Your submission was accepted", NotificationType.Success
     )
    )

     

     

  • CamCov Profile Picture
    123 on at

    @Drrickryp Thank you for the Help! This was exactly what I was looking for!

  • Chris1968 Profile Picture
    1,148 on at

    Hi, 

    I have similar problems with displaying the 'success' when a patch and with formula is part of the submit function.

    ClarkyPA365_0-1653396954779.png

    Where about would I put your example??

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