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 / Send Email to Addresse...
Power Automate
Unanswered

Send Email to Addresses Based on Form Dropdown Response and Corresponding Reference List

(1) ShareShare
ReportReport
Posted on by 4
Hello,
 
I have a question on my form that allows the user to select one or more of ~20 agencies from a dropdown menu. I need to have an email sent alerting that agency to a response on the form. I only know how to do this in Automate based on conditional formatting, which seems cumbersome for the number of agencies involved. I would like to build an email reference list, matched to the agencies in the dropdown list, for Automate to reference. 
 
What is the best app (standard) to build that reference list and what operation would I use to reference it? 
 
Thank you! 
Categories:
I have the same question (0)
  • David_MA Profile Picture
    12,982 Super User 2025 Season 2 on at
    I would do the following:
    1. Create a list on your SharePoint site for storing the e-mail addresses.
      1. Set the title column to enforce unique values so it can only be added once.
      2. Add a single line of text column named Email and populate it with the e-mail address. If you need to send it to more than one e-mail address at an agency, be sure to separate them by semicolons. For example, donald.duck@disney.com; mickey.mouse@disney.com; christopher.robin@disney.com.
    2. Then in your flow, add an apply to each set to the field that stores the agency names. Do not use the one from the dynamic content that is followed by value.
    3. In the Apply to each, use a get items from the list you created in step 1 with a filter query on the title of the current item agency name.
    4. Follow the get item action with a condition and use the length expression to make sure 1 item was found.
    5. On the yes side of the condition, you can use the e-mail address value in the list in step 1 in the to field to send the e-mail.
     
    Once you do this, you may need to find you want to tweak it based on your needs, but this should get you started.
  • EB-29041610-0 Profile Picture
    4 on at
     
    Thank you for the detailed answer. I'm confused on this part:
    1. Then in your flow, add an apply to each set to the field that stores the agency names. Do not use the one from the dynamic content that is followed by value.
    The flow is failing on this first part, likely because I'm using the dynamic content? There's only one option under "apply to each" that corresponds to the dropdown agency list on my form, if not dynamic content, what would I use? Here's the error:  ExpressionEvaluationFailed. The execution of template action 'Apply_to_each' failed: the result of the evaluation of 'foreach' expression '@outputs('Get_response_details')?['body/r6b41a57979a64b94bd2c3d9176316fb6']' is of type 'String'. The result must be a valid array.
  • David_MA Profile Picture
    12,982 Super User 2025 Season 2 on at
    Please share a screen shot of the configuration of the apply to each action. Without seeing how you configured it, it is hard to tell. Also, add a compose action to your flow and put the field that contains the agency values in it and be sure to put it before the apply to each. Run the flow and a screen shot of what is returned in the compose action.
  • EB-29041610-0 Profile Picture
    4 on at
     
    The "Agency of Pers.." is the dropdown question on the form with the agencies, and where the flow seems to be stopping in the test:
     
    Here is the second screenshot with compose set up with the same dropdown question from above (agency of personnel involved). The input and output fields match the selection I used on my test form, blacked out for privacy reasons:
     

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 525 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 324 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard