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 Automate / Wrong email in automat...
Power Automate
Answered

Wrong email in automated email flow

(0) ShareShare
ReportReport
Posted on by 18
Hi Community,
 
I have build a flow where, i am i want to add a step where if email id is invalid skip and send email to remaining list.
Now, it is sending email but status for flow is Failed ? How can i fix it ?
 
If anyone have encounter same issue ?
 
Also how will it tell which emails id were incorrect ?
 
Thank you 
Categories:
I have the same question (0)
  • Verified answer
    Nitesh Shrivastava Profile Picture
    23 on at
    Hello,
     
    Approach 1:

    You can add Condition to Validate Email in your cloud flow:

    • Add a "Condition" action.

    • Use the following expression in the condition to validate the email format:

      • matches(triggerOutputs()?['body/Email'], '^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$')

    • if the condition is true, set the IsEmailValid variable to true.

    To Skip Invalid Emails:

    • Add a "Condition" action to check the value of IsEmailValid.
    • If IsEmailValid is false, terminate the flow or skip further actions.
    • If IsEmailValid is true, proceed with the rest of the flow.
     
    Approach 2:
    If you have multiple emails addresses, you can put them in an array and send emails to individuals using the Apply to Each loop. In the loop you can also define Try catch condition.
     
    If I have answered your question, please mark it as the preferred solution . If you like my response, please give it a Thumbs Up 👍.
    Regards,
    Nitesh Shrivastava

     
     
  • Verified answer
    Riyaz_riz11 Profile Picture
    3,893 Super User 2025 Season 2 on at
    Hi,
     
    [Initialize email list]

    [Initialize variable: FailedEmails = []]

    [Apply to Each (email)]
      ├─ [Condition: is email valid?]
      │    ├─ Yes → [Scope: Send Email]
      │    │           └─ On Fail → [Scope: Failure Handler → Append email to FailedEmails]
      │    └─ No → [Append email to FailedEmails]

    [Send summary email or log failed addresses]
     
    If I have answered your question, please mark it as the preferred solution ✅ . If you like my response, please give it a Thumbs Up 👍.
    Regards,
    Riyaz

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 Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 519 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 296 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard