cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Send alert messagens when the form is sent

Hi!

I want to know if its possible to send an alert to the user when he submit the form, just a simple confirmation like "Form sent", or if something went wrong, "Error".

Im using PATCH, not an editform.

 

 

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Send alert messagens when the form is sent

Hi PeFischer,

 

How would you like the alert to be sent?

In PowerApps, there are Errors function that would return the error message if the data didn't write to the data source correctly, and we could take use of SendEmail function to send the error details in PowerApps.

There is no function available to check if the data has been updated, which we need to set additional audit or trigger from the data source side.

For the errors function, and the SendEmail function, please see:

Errors function in PowerApps

Office 365 outlook

For example, we could write the following formula with the Submit Button onselect property:

If(Patch(Datasource, Baserecord, changeRecord),

   SendEmail(To, Subject, Body),

    SendEmail(To, Subject, Errors(Datasource).message)

  )

The formula above would send the error message in Email body if patch failed, but if there is no errors, it would trigger another email, which should mean the patch works(Which should be confirmed at the data source side).

Hope this is helpful.

Regards

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Highlighted
Community Support
Community Support

Re: Send alert messagens when the form is sent

Hi PeFischer,

 

How would you like the alert to be sent?

In PowerApps, there are Errors function that would return the error message if the data didn't write to the data source correctly, and we could take use of SendEmail function to send the error details in PowerApps.

There is no function available to check if the data has been updated, which we need to set additional audit or trigger from the data source side.

For the errors function, and the SendEmail function, please see:

Errors function in PowerApps

Office 365 outlook

For example, we could write the following formula with the Submit Button onselect property:

If(Patch(Datasource, Baserecord, changeRecord),

   SendEmail(To, Subject, Body),

    SendEmail(To, Subject, Errors(Datasource).message)

  )

The formula above would send the error message in Email body if patch failed, but if there is no errors, it would trigger another email, which should mean the patch works(Which should be confirmed at the data source side).

Hope this is helpful.

Regards

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020 Winner Announced

Check it out!

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (12,053)