cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JoseGonzalez
New Member

Switch block is skipping a case, even when the condition is met.

I have a flow where a Switch block sends an approval request to a user, based on a form question selection.

The form question is being properly read, as per prior steps are working ok.

 

However, when the switch block is activated, it skips (marks as false) all of the given conditions, even the one that is true:

Capture.PNG

 

Here's my entire flow:

 

Flow.JPG

3 REPLIES 3
efialttes
Super User
Super User

Hi!
Is your Switch evaluating Outcome output?
Please share a screenshot from your flow design, ensuring details from your switch are displayed
Gracias!


Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Hi, thanks - I updated my original message. Thanks

efialttes
Super User
Super User

Hi!

Sorry for the misunderstanding! I initially thought your switch was evaluating the Approval result.

My suggestion is, to add a 'Compose' action block just before the Switch ad assign as its input the same dynamic content you assigned as the Switch input. THis way you can reexecute the flow and inspect its results.

 

A usual problem is a extra space in your data ,so no matter it looks the same, since Switch requests exact match it will fail. Assuming you stored the data to be evaluated in a string variable called 'myInputData', you can use replace() to remove all spaces by means of the following expression:

replace(variables('myInputData'),' ','')

...and now compare it against

JosePabloGonzalez

 

You can also use toUpper() to avoid mismatches between capital letters and small letters

 

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (3,197)