Hi
I new to Powerapps and have created a simple application which enables user to write data to a SharePoint List. I am also using the Office365Outlook.SendEmail function to send a fancy html email upon submission of the form.
I am using if statements to send emails depending on what data is inputted or selected on the entry form. Here is my formula:
Office365Outlook.SendEmail(
"jon@hotmail.co.uk" & If(
DataCard1.Selected.Value = "Chicken Soup",
"jane@hotmail.co.uk"
),
"Subject: " & DataCard2,
'HTMLEmail'.HtmlText,
{
IsHtml: true,
Importance: "High"
}
) & SubmitForm(Form1);
NewForm(Form1);
Navigate(
'Thank You Screen',
ScreenTransition.Fade
)
So when a user submits a form, all emails are sent to jon@hotmail.co.uk. But if Chicken is selected in the DataCard1 Combo box, then this includes jane@hotmail.co.uk into the email also.
This worked for a bit, but now when DataCard1 meets the criteria of "Chicken" it seems to break and I get the attached error message and no email is sent to anyone.
Not sure if its me or something else, but I need someones help to resolve this.
Thanks,