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

Email help from Powerapps

Can someone please tell me what I am missing with this?

Office365.SendEmail(
    ThisItem.Email,
    "Installation at : " & ThisItem.Address,
    "Thank You " & ThisItem.Agent,
    Char(10),
    "Your sign at " & ThisItem.Address,
    "has been installed by " & ThisItem.Installer,
    {
        Attachments: MyPhoto,
        Importance: "High",
        IsHtml: true
    }
)
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Solution Sage
Solution Sage

Re: Email help from Powerapps

Try...

 

InstallerDropdownControlName.Selected.Value

View solution in original post

7 REPLIES 7
Highlighted
Solution Sage
Solution Sage

Re: Email help from Powerapps

You have to concatenate all parts of your body portion...

 

Office365.SendEmail(
    ThisItem.Email,                                        <--To
    "Installation at : " & ThisItem.Address,               <--Subject
    "Thank You " & ThisItem.Agent &                        <--Body
    Char(10) &                                             <--
    "Your sign at " & ThisItem.Address &                   <--
    "has been installed by " & ThisItem.Installer,         <--
    {                                                      <--Other message meta
        Attachments: MyPhoto,
        Importance: "High",
        IsHtml: true
    }
)

 Otherwise, after your initial statement of "Thank you [Agent]" the compiler interprets you to be at the next argument of the SendEmail() function (because of the comma).

 

Watch the pop-up help tag of the formula you are working on. The argument you are in (for any given cursor insertion) will be bolded so you know where you are in the formula.

Highlighted
Helper IV
Helper IV

Re: Email help from Powerapps

Thank you for the help and uderstanding of this.  Once I make those changes I am now getting an "Invalid argument type. Expecting one of the following: Text, Number, Boolean."

Highlighted
Solution Sage
Solution Sage

Re: Email help from Powerapps

Where in the formula is it highlighting? Can you post a screenshot of the formula box?

 

Try removing everything after the Body argument (so the comma following and everything between the {}). See if that simplifies things and if the problem goes away.

Highlighted
Helper IV
Helper IV

Re: Email help from Powerapps

The issue is at ThisItem.Installer.

 

This item is a dropdown box where you select the installer

Highlighted
Helper IV
Helper IV

Re: Email help from Powerapps

Forgot the screenshot.  Here you go.Screen.png

Highlighted
Solution Sage
Solution Sage

Re: Email help from Powerapps

Try...

 

InstallerDropdownControlName.Selected.Value

View solution in original post

Highlighted
Helper IV
Helper IV

Re: Email help from Powerapps

Yes that was the problem!

 

Thank you

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

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 (7,628)