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

Send email with options to multiple users

Need some assistance. I want to send an email with options to every row in the list filter by a group to site owners using flow but the site owner column is not resolving to be a valid email address(es). The site owner column is just plain text with names of employees separated by a semi-colon due to import from Excel file.

 

Error message is "The 'inputs.parameters' of workflow operation 'Send_email_with_options' of type 'OpenApiConnectionWebhook' is not valid. Error details: Input parameter 'optionsEmailSubscription/Message/To' is required to be of type 'String/email'. The runtime value '"name, one; name, two"' to be converted doesn't have the expected format 'string/email'."

 

P.S. Ignore the "Initialize Variable"

 

Thank you for any assistance.

1122

 

list.jpg

1 ACCEPTED SOLUTION

Accepted Solutions
Ramiz
Helper III
Helper III

Dear @normmsnpoweruse 

You can achieve this by appending all emails to a string variable and then use that in send an email(v2) . See the attach images. If you are running this on multiple items you need to reset the append variable each time. Here Reset is a string variable with empty value and To is my Person or Group field.

Screenshot_9.pngScreenshot_12.png


View solution in original post

12 REPLIES 12
Diksha
Resolver IV
Resolver IV

Hello @normmsnpoweruse ,

 

As the site owners column is a plain text , you won't be able to get the email address of owner . 

The column should be of Person or Group type  and while importing data from excel , you have to pass the email address instead of name of owner to this column . 

 

Once you have the Person or group column values with this emails , you will be able to use those values in Send an email with options To field.

 

If this answered your question, please mark this question as answered and if you liked my response, please consider giving it a thumbs up .
Thank You !!!

 

 

 

I removed the compose action since it was giving an error message. I created a new "site owners v1" column with person or group type as said.  My flow is only picking up the very first name. It is not sending to the email to other owners of the item.

 

3.jpg

Hello @normmsnpoweruse ,

 

When you select the multiple selections enabled dynamic content “Person or Group” column, an Apply to each will be added automatically. Then flow will consider each person as a recipient and send an email to the email address.

 

I can see from the screenshot you have shared , Apply to each loop is added which will send a seperate emails to all the users you have added in the Site Owners V1 column.

 

Can you please check with those users if they have received an email ??

 

 

If this answered your question, please mark this question as answered and if you liked my response, please consider giving it a thumbs up .
Thank You !!!

 

 

Actually, the flow will send the email to the first person only on the site owner column of the item. My flow is ignoring other emails on the same item.

 

This is my goal...

 

For example, the site owner column has 3 people, I want the flow to send ONE email to these 3 people so all these recipients will see that the other persons got the email too. 

 

I really appreciate your help.

You can't send just 1 'Email with options' to multiple users, it's 1 email per person. If you want one email to multiple users with some options, you'll have to use the 'Start and wait for an approval' action with custom responses, which is very similar from the functionality perspective.



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

It is working now but the flow is sending one email instead of two emails for two SharePoint list items to all site owners. For example, item one has two site owners, item two has one site owner. My flow would send one email to all 3 site owners 😞

 

8.jpg

That's because you're 'appending' into the same variable in all the loops. You should empty the variable inside the 'Apply to each 3' (set the variable value to expression 'null') before you move into the 'Apply to each' and start appending email addresses again. And the 'Send an email' should be inside the 'Apply to each 3' if you want to send a separate email for each item. Right now you're just adding all emails into a single string and then sending a single email to all recipients in that string.

 

Apply to each 3

- Set variable to null

- Apply to each

- - Append to string variable

- Send an email



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

Hello @normmsnpoweruse ,

 

Use the Send Email action outside the Apply to each loop and inside the Apply to each 3 loop.

 

Also, after this Send an Email add one more action to make varSiteOwnerEmail variable as blank so that it will add new owners for next item and send email to those owners only.

 

If this answered your question, please mark this question as answered and if you liked my response, please consider giving it a thumbs up .

Thank You !!!

Ramiz
Helper III
Helper III

Dear @normmsnpoweruse 

You can achieve this by appending all emails to a string variable and then use that in send an email(v2) . See the attach images. If you are running this on multiple items you need to reset the append variable each time. Here Reset is a string variable with empty value and To is my Person or Group field.

Screenshot_9.pngScreenshot_12.png


View solution in original post

normmsnpoweruse
Helper III
Helper III

Thank you all for your input. They were all helpful especially the solution!

This is just frustrating. Email variable doesn't reset when using Send Email With Options due to the fact it is waiting for an input from recipient.

 

What's my option now to get a reply? Should I use start an approval process or send the recipient to update the item by sending to the SharePoint list?

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Users online (2,718)