web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / how to send an email t...
Power Apps
Unanswered

how to send an email to multiple people selected form a gallery list in powerapps

(0) ShareShare
ReportReport
Posted on by 8

how to send an email to multiple people selected form a gallery list in PowerApps and not get this

JAY_dev_1-1593435626366.png

 

i only want one email address to show there

Categories:
I have the same question (0)
  • lr Profile Picture
    26 on at

    Hi, 

    maybe you can use a ForAll function, to send a separate email to every selected user. 
    https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-forall

    Best regards

  • JAY_dev Profile Picture
    8 on at

    Can i implement this in to a flow sorry i have used the ForAll before and i don't see how it will work, can you please explain a bit more

  • v-bofeng-msft Profile Picture
    on at

    Hi @JAY_dev :

    Do you want to collect the email addresses selected by the gallery and send messages to these email addresses?

    I suggest that the Concat function connect the selected addresses with ";" so that you can send multiple emails at once.

    I'v made a test for your reference:

    1\My data source:

     

    ClearCollect(TheMail,{mail:"XX@XXXXXX.com"},{mail:"bof@XXXXXXXX.com"},{mail:"46XXX71@qXXX.com"},{mail:"XXXng@XXXXXt.com"}) /*TheMail is my custom collection*/

     

    2\Add a gellry

    Items

     

    TheMail

     

    3\Add an arrow into this gallery

    OnSelect

     

    Collect(waitforsent,{mail:ThisItem.mail}) /*waitforsent is my custom collection*/

     

    4\Add a lable(Used to show the result of the concat function, you can skip this step)

    Text:

     

    Concat(waitforsent,mail,";")

     

     5\Add a button (you should add an office365outlook connection first)

    OnSelect

     

    Office365Outlook.SendEmailV2(Concat(waitforsent,mail,";"),"Subject","Body");Clear(waitforsent)

     

    27.gif

    I think this link will help you a lot

    Send an email (V2)

    Best Regards,

    Bof

     

  • JAY_dev Profile Picture
    8 on at

    that looks good and all but i don't think it will help me with the 100+ email accounts i need to work with and more are going to be added for new clients and going back to change the code every time a client get added or removed seems a bit wasteful,

     

    thanks for trying to help me sorry I'm so full of nonsense but i need this to be exact because it what my client asked for.

    i did do the (concat) funtion to send multiple email wich works fine however i need it not to show the email all addresses  i sent the email to.


    i need this

    JAY_dev_1-1593497040666.png



    not this

    JAY_dev_2-1593497110662.png

     

     

     

  • v-bofeng-msft Profile Picture
    on at

    Hi @JAY_dev :

    Because you mentioned "selected by gallery", I thought you need to select the required email addresses one by one in the gallery.

    I am not sure if I have understood your needs now, can you help me point out my mistakes?

    • you have a list of email accounts
    • You show these emails in a gallery
    • You want to send mass emails to all email addresses in the gallery

    If my understanding is correct, you can try this code:

     

    Office365Outlook.SendEmailV2(Concat(Gallery10.AllItems,mail,";"),"Subject","Body");Clear(waitforsent)

     

    Or

     

    ForAll(Gallery10.AllItems,Office365Outlook.SendEmailV2(mail,"Subject","Body"))

     

     Best Regards,

    Bof

  • JAY_dev Profile Picture
    8 on at

    sorry looks like i did not explain very well , in my app I am creating an html document and then im converting it to pdf format in a flow now what i need is to send emails to all the people associated with the document with out the being multiple email addresses in the (To:) area of the email see the images of my previous post , i need  there to be only the email address of the person i am sending to 

  • v-bofeng-msft Profile Picture
    on at

    Hi @JAY_dev :

    Could you tell me where the email address is stored? How to get it?

    Best Regards,

    Bof

  • JAY_dev Profile Picture
    8 on at

    in SharePoint lists witch I'm pulling to powerapps

  • v-bofeng-msft Profile Picture
    on at

    Hi @JAY_dev :

    Could you tell me:

    Where are you stuck now? Are you currently unable to send mail to multiple people? Still can't get the email address? Still can't send a PDF?

    If it is not possible to send an email to multiple people or to obtain an email address, the solution I gave directly should be available.If not,could you describe the details in detail?

    Best Regards,

    Bof

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard