cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Send email to list of addresses contained in a collection

Hi all,

 

I am facing the follwoing issue.

I have made a form in which I select an email address from a dropdownd menu. I can do this action as many time as I need it. Each time I select an item, if I press an add button the item is added to a collection and showed in a listbox.

I want to send an email to all the select addresses using office365.sendemail function (or in any other way) but I don't know how to pass multiple addresses taken form the collection.

 

Any help much appreciated!

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Re: Send email to list of addresses contained in a collection

Hi,

it seems I solved the issue.

 

I select a name from a dropdown menu. Then, using a button I have put:

Collect( Operators; { Name: Dropdown1.Selected.Fullname; address: Dropdown1.Selected.userid } )

where Operators is my collection of name, email

 

I show the collection in a list and finally I have another button named send alert which have the following commands.

 

Office365.SendEmail(Mid(Concat(Operators; ", " & address); 3; 1000);"You will be added to the registry";"Please use the app to provide your personal details")

 

It works 🙂

Now I have just to figure out how to remove an entry from the collection using a recycle bin icon.

View solution in original post

3 REPLIES 3
Super User
Super User

Re: Send email to list of addresses contained in a collection

I want the same functionality inone of my apps, but unfortunately there's not way of doing that using Office365.Sendmail; you can't use that in a ForAll.

 

The advice I got when asking about it in the forum was to use Flow, but I haven't tried that yet. Hopefully you can run a Flow in a  ForAll loop. If you go with the Flow, please update here how you fared.

Anonymous
Not applicable

Re: Send email to list of addresses contained in a collection

Hi,

it seems I solved the issue.

 

I select a name from a dropdown menu. Then, using a button I have put:

Collect( Operators; { Name: Dropdown1.Selected.Fullname; address: Dropdown1.Selected.userid } )

where Operators is my collection of name, email

 

I show the collection in a list and finally I have another button named send alert which have the following commands.

 

Office365.SendEmail(Mid(Concat(Operators; ", " & address); 3; 1000);"You will be added to the registry";"Please use the app to provide your personal details")

 

It works 🙂

Now I have just to figure out how to remove an entry from the collection using a recycle bin icon.

View solution in original post

Super User
Super User

Re: Send email to list of addresses contained in a collection

Great job! I'll see if I can use the same trick to send a message to a bunch of people.

 

Is the bin icon in the gallery, next to each row? If so it's easy, just use

 

Remove(Operators, ThisItem)

If the bin icon is outside the gallery, you can delete the selected item with 

 

Remove(Operators, Galleryname.Selected)

Thanks, and good luck!

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (4,257)