cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper II
Helper II

Send confirmation mail to form submitter when task status is completed

Hi,

I have a manually created form(not the ready made form of powerapps). When user fill the field and clicks submit button,Task Status is shown as "New" for that user.
I want to send confirmation email to that user if Task Status is changed from "New" to "Completed".

How can i get that user's email when he/she submitted the form and how to send that user an email?
Can anyone give me a detailed solution regarding this?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @MKMUMU :

Could you tell me what your data source is? Share Point? CDS?

Do you want to know how to get the email address of the creator of a record?

Do you want to know how to send that user an email if the Task Status is changed from "New" to "Completed"?

I assume your data source is Share Point list.( It has a system field "Created by", which records the information of the creator of the record)

I’ve made a test for your reference:

Here is my data source: List B

Column (click to edit)

Type

Title

Single line of text

Field A

Single line of text

Field B

Single line of text

Employee Name

Person or Group

cchoice

Choice

Task Status

Single line of text

1\Add Office 365 Outlook as your data source.

View-Data sources-Connectors-Office 365 Outlook-Add a connection

a.jpg

 

2\ Put this code after your code which is used to change the task status:

 

 

If(
    First(
        Sort(
            'List B',
            Modified,
            Descending
        )
    ).'Task Status' = "Completed",/* Find the most recently modified item */
    Office365Outlook.SendEmailV2(
        First(
            Sort(
                'List B',
                Modified,
                Descending
            )
        ).'Created By'.Email,/*Get the user’s email address*/
        "Subject",/*the email’s subject*/
        "Body"/*the email’s body*/
    )
)

 

 

Best Regards,

Bof

View solution in original post

2 REPLIES 2
Community Support
Community Support

Hi @MKMUMU :

Could you tell me what your data source is? Share Point? CDS?

Do you want to know how to get the email address of the creator of a record?

Do you want to know how to send that user an email if the Task Status is changed from "New" to "Completed"?

I assume your data source is Share Point list.( It has a system field "Created by", which records the information of the creator of the record)

I’ve made a test for your reference:

Here is my data source: List B

Column (click to edit)

Type

Title

Single line of text

Field A

Single line of text

Field B

Single line of text

Employee Name

Person or Group

cchoice

Choice

Task Status

Single line of text

1\Add Office 365 Outlook as your data source.

View-Data sources-Connectors-Office 365 Outlook-Add a connection

a.jpg

 

2\ Put this code after your code which is used to change the task status:

 

 

If(
    First(
        Sort(
            'List B',
            Modified,
            Descending
        )
    ).'Task Status' = "Completed",/* Find the most recently modified item */
    Office365Outlook.SendEmailV2(
        First(
            Sort(
                'List B',
                Modified,
                Descending
            )
        ).'Created By'.Email,/*Get the user’s email address*/
        "Subject",/*the email’s subject*/
        "Body"/*the email’s body*/
    )
)

 

 

Best Regards,

Bof

View solution in original post

thank You Bof....for your detailed guiding...really appreciate your help..😊

Helpful resources

Announcements
News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (6,420)