Skip to main content

Notifications

Power Automate - Building Flows
Answered

How can I include multiple dynamic content in an email without sending it twice

Posted on by 66
Hi,
 
my situation is this, I have a flow where I've used the Get Emails (outlook) action and Get Items (sharepoint) action. Then used the Send an email from a shared mailbox (V2) action. I use the get items to determine the emails I need then send items with the email content. The flow is sending two emails but I only want it to send one. I assume it's something to do with the for each being inside apply to each. Any advice on how I could fix this? I think I've heard you can do this by creating arrays but I wouldn't know how. Any advice would be very much appreciated. 
 
Photos of the array and content for reference:
 
Thank you,
 
 
 
  • LB-20090315-0 Profile Picture
    LB-20090315-0 66 on at
    How can I include multiple dynamic content in an email without sending it twice
    Thanks Nived,
     
    I doubled checked and there were two emails. Can't believe I didn't realise. I've removed the extra one and it works fine now thank you. 
  • Verified answer
    Nived_Nambiar Profile Picture
    Nived_Nambiar 16,591 on at
    How can I include multiple dynamic content in an email without sending it twice
    Hi,
     
    get emails may be retriving 2 emails - so the for each loop may be having 2 iterations (i hope for each loop is looping based on get emails) which causes to send email twice.
     
     
     
    Thanks & Regards,
    Nived N
  • LB-20090315-0 Profile Picture
    LB-20090315-0 66 on at
    How can I include multiple dynamic content in an email without sending it twice
    Well, the get items is being filtered using a date filter. It is retreiving items from a sharepoint list based on their due date. 
     
    The compose has been used to write a table for the email in which I have used dynamic content from the sharepoint data. 
     
    The get emails has searched my outlook inbox and found emails based on the names in the sharepoint list. 
     
    The send email is using dynamic content from the compose and the get emails in the body. It's just set up to send to my email. 
     
    I don't know why exactly but it sends me two emails. 
     
    Hope that explains a bit. 
  • Nived_Nambiar Profile Picture
    Nived_Nambiar 16,591 on at
    How can I include multiple dynamic content in an email without sending it twice
    Hi
     
    the for each loop seems to be iterating twice - that may be the reason why 2 emails are sent instead of one
     
    Could you give idea of this flow - did not get what exactly you are trying to do here :)
     
    Thanks & Regards,
    Nived N

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

November 2024 Newsletter…

November 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #7 Community Profile Tips…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 143,532

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 64,050

Leaderboard