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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Flow: Loop through For...
Power Automate
Answered

Flow: Loop through Form Responses and Check For Specific Answer

(0) ShareShare
ReportReport
Posted on by 4

Hello,

 

I am to setup many Forms with many questions, all with only three available answers to each question. Is there a method to loop through the form responses one by one?

 

For example,

If I have a Form with 30 questions, each question can only be answered with "Yes, No, & Maybe". I would like to conditionally send an email to a person if there are one or more answers as "No", to notify them that something is wrong.

Is it possible to loop through the collection of form responses and compare the answers to see if any one of them equals "No"? 

Categories:
  • Verified answer
    v-litu-msft Profile Picture
    Microsoft Employee on at

    Hi @seth350,

     

    Unfortunately, there is no way to loop through the collection of form responses of Form directly.

    As a workaround, you may need to construct a lengthy and repetitive Flow to put these responses into an array, like as below:

    Initialize an array variable, and then append these Responses of questions, because you have 30 questions, so you may need to create 30 Append to array variable actions.

    Annotation 2019-11-13 141033.png

    After the repetitive and simple operation, you can use the Apply to each action to loop through these responses by using expression item()?['Response']. And then you can compare the answers to see if anyone of them equals "No" by using Condition action.

    Annotation 2019-11-13 141102.png

     

    Best Regards,
    Community Support Team _ Lin Tu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • seth350 Profile Picture
    4 on at

    Thank you very much for the solution.

  • TruePowerApps20 Profile Picture
    48 on at

    Thanks for this post as it really helped me with coming up with the solution I needed!

    Just to add on to this excellent guide, for my use case I was needing the flow to scan the list of responses for any instance of a "Fail" and then do a single output based on the condition. With the way this instruction is written I was getting an email for every FOREACH loop that met the conditions.

    To get around this, right after we Initialized the "Response" variable I initialized a second variable named "Result" as type "String" where the default value is "Pass".

     

    Variable.jpg

     

    Then I put a condition directly after the Compose Loop to check for the result to = "Fail" and then it sets the variable "Result" to "Fail".

     

    SetVariable.JPG

     

    This is then later used to decide which email should go out (Pass/Fail).

     

    Email.Jpg

     

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 298 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 289

#3
Henil Profile Picture

Henil 125

Last 30 days Overall leaderboard