
Announcements
I'm working with a user in our org that is attempting to add automatic weights to some of the multiple choice questions in their MS Form. Form response triggers the flow -> variable is changed to the weighted value -> then the data is added to an Excel table. I keep getting the error when attempting the process laid out here.
I believe I have set up my flow to mimic this, but I keep getting an error in the Switch part of the flow.
This is the error I receive: The execution of template action 'Set variable' failed: an unexpected exception encountered when evaluating branching condition.
I am new to Flows so I am just looking for some assistance. I will post my Flow in edit mode below. Thank you!
I googled that error message and came across this post where someone had a similar error. This was happening because the form was returning a string and the switch is trying to compare it as a number, they resolved this by changing 1, 2, 3, etc. in the switch cases to "1", "2", "3" but you could probably also change the "On" field in the switch to cast the response to an int as well with an expression like `int(body('Get_response_details')?['r1234567890...'])`