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
Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

secondImage

Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

secondImage

Super Users Coming in August

We are excited for the next Super User season.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (7,839)