Is there any a way to hide the following error message:
Office365Outlook.SendEmail failed: { "status": 400, "message": "Parameter 'To' cannot be null or empty.\r\nclientRequestId: cdb56a4a-1218-44f6-8d01-2969df19bd08", "error": { "message": "Parameter 'To' cannot be null or empty." }, "source": "office365-we.azconn-we-01.p.azurewebsites.net" }
It is a Lookup function of the email address linked to a user's name and when Saved the person receives the email. There are a few without email addresses which will and should not receive the mail. But they receive the error message when saved and moved to the next screen.
Solved! Go to Solution.
Hi @Mareliese ,
According to your description, I think you could change the way.
You could try the If() function to determine whether the user has a mailbox.
If the user has a mailbox, use the function Office365Outlook.SendEmail().
If the user does not have a mailbox, the function Office365Outlook.SendEmail() will not be used.
You could refer to the following formula:
If(!IsBlank(***),Office365Outlook.SendEmail(***))
Best Regards,
Wearsky
If my post helps, then please consider Accept it as the solution to help others. Thanks.
hi @Mareliese
Yuu are almost there ;), the Sendmail part requires an email, subject and body. all you have to do is add the subject and body. for this reason the error is revceived 1 (you have an email address), expects (Subject, Body).
hope it helps
Hi @Mareliese ,
According to your description, I think you could change the way.
You could try the If() function to determine whether the user has a mailbox.
If the user has a mailbox, use the function Office365Outlook.SendEmail().
If the user does not have a mailbox, the function Office365Outlook.SendEmail() will not be used.
You could refer to the following formula:
If(!IsBlank(***),Office365Outlook.SendEmail(***))
Best Regards,
Wearsky
If my post helps, then please consider Accept it as the solution to help others. Thanks.
Thank you Wearsky.
Clearly I'm still missing something / some understanding.
I've amended the formula to:
If(!IsBlank(DataCardValue_AuthorisedEmail.Text),Office365Outlook.SendEmail(DataCardValue_AuthorisedEmail.Text)),
But now I'm receiving the following error message:
Invalid number of arguments: received 1, expected 3-4.
What am I missing?
Thank you
hi @Mareliese
Yuu are almost there ;), the Sendmail part requires an email, subject and body. all you have to do is add the subject and body. for this reason the error is revceived 1 (you have an email address), expects (Subject, Body).
hope it helps
Thank you Rubin.
Your timing is perfect. I've just managed to sort the formula.
The mail sends when there is an email address.
When no email address, there is no longer an error message.
And the Apps moves to the next screen without any hiccups.
Thank you.
great stuff, enjoy the app.
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
User | Count |
---|---|
197 | |
69 | |
47 | |
36 | |
25 |
User | Count |
---|---|
239 | |
110 | |
89 | |
88 | |
66 |