Oct 09 2023 11:41 PM - edited Oct 17 2023 09:12 PM
Thank you for your assistance in advance.
This flow runs when a response is submitted in a MS Form. The form is collecting information for services offered. The services are contained in a SharePoint List. The data from the MS Form is copied across to another SharePoint List.
There are a lot of options and the flow is told to what to do if different services selected.
I noticed that the flow fails if the services shown below are true. It actually tries to send the response down the not true path and then fails.
Any geniuses out there who can help with this one please???
Oct 10 2023 07:03 AM
Hi @Cdstrev,
solution is to use the Filter array action to filter the Services dynamic content to only include the services specified in the If condition, and then iterate over the filtered array using the Apply to each action.
Here is an example flow:
Trigger: When a new response is submitted in Microsoft Forms Actions: 1. Get form response details 2. Filter array (value: Services, filter condition: equals, value: 9) 3. Apply to each (items: filtered services): * Do something with the current service 4. End of flow
Here are some links for reference:
Oct 10 2023 02:19 PM - edited Oct 17 2023 04:53 PM
Thank you for your response. Could you please assist me with where the filter array would go?
Oct 12 2023 12:19 AM
Hi @Cdstrev,
thanks for your screenshot and your update.
To add a filter array action to your flow in the image you provided, follow these steps:
Once you have added the filter array action, you can connect it to the Apply to each action. To do this, click the Select output from previous steps button and select the Filtered services dynamic content.
You can place the filter array action before or after the condition action, but it is generally best to place it before the condition action so that you are only filtering the services that are relevant to the condition.
Here is an example of how to place the filter array action before the condition action:
Trigger: When a new response is submitted in Microsoft Forms Actions: 1. Filter array (value: Services, filter condition: equals, value: 9) 2. Condition (condition: Service equals 9) * Yes: Do something with the service * No: Do something else 3. End of flow
This flow will only iterate over the services that match the filter condition (Service equals 9). If the service does not match the filter condition, then the flow will skip the Do something with the service action and go straight to the End of flow action.
Please click Mark as Best Response & Like if my post helped you to solve your issue.
This will help others to find the correct solution easily. It also closes the item.
If the post was useful in other ways, please consider giving it Like.
Kindest regards,
Leon Pavesic
(LinkedIn)