I'm having an issue with the SendMail function in my PowerApps app linked to 2 SharePoint Lists (1 is irrelevant here).
As you can see on the 1st image, I have a SharePoint List named "Dépôt commande e-mails" where I have the full names and Office360 Outlook emails of my colleagues.
The app itself is a form, and when someone submits the form, it is supposed to send an email to everyone in the SharePoint list of emails. In the OnSuccess of the form, you can see the full formula on the second image.
What I'm struggling with here is, as better seen on the third image, I used a Concat() function to get all the emails of the SharePoint list as a string, separated each by ", " (comma + space) as the "To" parameter of the mail.
While it was working perfectly fine with me, when someone with a different mail than the ones in the list used the app and submitted their form it displayed an error message saying that the "To" parameter of the email (so the Con
cat() function) isn't valid.
Why does this happen to other users except the ones in the list ? Am I doing something wrong ?
Solved! Go to Solution.
Wonder if this has to do with the comma separated email addresses, not sure if it this a cultural/regional setting. I always use a semicolon which I believe is the default separator for Outlook (which can be changed in Outlook to commas). Try changing your separator to semicolon and see if that works for both you and the other user.
The error message does indicate is has something to do with what is being passed to the <To> Parameter, can you put the results of what is getting passed to that field in a label so you can see the value and post a screen shot of that?
Glad to hear it, makes sense as they were getting no items returned and the 'To' parameter was blank causing the error, would have been nice to have an access denied message, would have been a little easier for you to find the issue.
Keep up to date with current events and community announcements in the Power Apps community.
A great place where you can stay up to date with community calls and interact with the speakers.
Check out the latest Community Blog from the community!