Power Automate: Save multi-choice Microsoft Forms

The team ran into this issue while parsing multi-choice Microsoft Forms elements into SharePoint using Power Automate. The problem is described correctly in the Power Automate Forum Question that asks why can’t we get the value from a multi-select field in Microsoft Forms and send it to SharePoint?

Since we don’t know which options the user will select, we need to use the dynamic field in Power Automate to provide the fields that come from Form and cannot use the dropdown where we pick the options.

The first try

If I have a form like this?

I should be able to do this on Flow, and it would work, right?

Let’s look at the SharePoint column configuration:

I have the same options in SharePoint; when I run Power Automate, all goes well, but then looking at SharePoint, it’s empty. Why?

The issue

The issue is simple, and you can see it right away in Power Automate’s history:

I don’t have an option with the value[\"Option 1\",\"Option 3\"]. To understand the issue, we need to know something about Microsoft Forms. Everything that comes as a reply is a String, regardless of you configure in Microsoft Form. For example, if you set a multi-choice Microsoft Form as we did, Microsoft Forms returns a string with an “array” of elements. It’is not usable for us since we need something that Power Automate understands and can send to SharePoint.

Checking the format

It’s simple to check the format that we need. In the “Create Item” pick two items like so:

… and we get:

Quite a difference, right?

So we have a JSON array with two key/pair elements, and we need to get there.

So now we know the solution. We need to transform:

[\"Option 1\",\"Option 3\"]


    "Value": "Option 1"
    "Value": "Option 3"

Before we start

I have to warn you that this is a workaround. We need to parse a string to a JSON format, and so we need to do some work. To make it simple, I’ll break it down into steps, so it’s easier to understand. It may look complicated, but once you know each stage it’s quite straightforward.

Here’s the overview of the Power Automate:

Don’t try to build it yourself. Go to my template section and download it.

Get the “clean” options

First, let’s lean the string that we get. To do that we’ll use our friend the “Compose” action:

And the formula is the following:


SCARY!!!  🙀

Not really what we’re doing is the following:

  1. Get the value from the body:
[\"Option 1\",\"Option 3\"]
  1. Replace the value “[” with nothing. We get:
\"Option 1\",\"Option 3\"]
  1. Replace the value “]” with nothing. We get:
\"Option 1\",\"Option 3\"
  1. Replace the “ with nothing. We get:
Option 1,Option 3

Not bad. Now we have a comma-separated string, so it’s time to generate an array to parse the information better.

Form an array

Our trusted “Compose” action will allow us to generate an array quickly:



The formula is quite more straightforward than the previous one. Split the string using the, as the separator. You’ll get something like this:

Looking good. Nice and clean array. Now we can iterate in each element of the list and generate the values in the format we’ve seen previously.

The variable

Before we can generate the information in the format that Power Automate wants, we need a place to store it. To do that, we can create a variable:

Why an array and not a string? Because Power Automate expects an array of objects, so we can use the variable to do the conversion work for use. If we used a string, we would need to concatenate a lot of characters to simulate an array, and that would be quite an error-prone.

The final step – Bringing all together

We need to form the tuple that Power Automat expects:

Value : "Option X"

Here’s the step

And the formula is the following:


We’re concatenating the tuple as requested in a JSON format and then converting it into a JSON object to append to the array. Each value of the array will look like this. It looks familiar, doesn’t it?

Save to SharePoint

Ok let’s save this array to SharePoint:

When we run the Power Automate, we’ll see something that looks a lot better.

Perfect format.

Now let’s check SharePoint. Fingers crossed 🤞

If you’re suspicious that the options are not selected let’s edit the element:

It works 🎉

Take home message

Microsoft Forms is a fantastic tool, but we have to be aware of these tiny topics that can complicate a little bit of our life. Multi-choice Microsoft Forms are widely used, but I’m sure that you ran into this issue in the past. Hopefully, the solution is clear and useful for you.

Again, you don’t want to build all of this yourself! You can jump to my template section and grab the template already done for you.

Have a suggestion of your own or disagree with something I said? Leave a comment or interact on Twitter and be sure to check out other Power Automate-related articles here.

Photo by Nathan Dumlao on Unsplash

Manuel Gomes

I'm a Project Manager with experience in large projects and companies. I've worked in the past for companies like Bayer, Sybase (now SAP) and I'm currently working for Pestana Hotel Group.

View all posts by Manuel Gomes →

19 thoughts on “Power Automate: Save multi-choice Microsoft Forms

    1. Hey Melissa,

      Indeed, but you can import the template and use it for all of them to not need to replicate the code. Just import the template and use it as a “function” within your Power Automate.


    1. Hi Chase,

      Honestly, I can’t think of one when I wrote this article, but one may exist.
      Do you have an idea? I would be more than happy to improve the article :).


  1. Hello Manuel,

    I seem to have a problem on the ‘apply to each’ section. I keep getting the following error:

    The execution of template action ‘Apply_to_each’ failed: the result of the evaluation of ‘foreach’ expression ‘@outputs(‘Generates_the_array’)’ is of type ‘String’. The result must be a valid array.

    My form has a choice question with six or seven choice. When it get posted to SharePoint it has all the brackets, quotes, comma and others. I can post the response data with the flow I created, though when I try with your template I keep getting stopped at ‘Apply to each’ with my Flow.

    1. Hello Mark,

      It looks like you have a string in the “Apply To Each” action. Can you please check, in the definition of the variable ‘Generates_the_array’, that you’re defining it as an Array and not a String?


    2. Hello Mark,

      It looks like you have a string in the “Apply To Each” action. Can you please check, in the definition of the variable ‘Generates_the_array,’ that you’re defining it as an Array and not a String?


  2. I’ve check and it is set up from an Array. There in nothing in ‘Initial Value’ though. Thanks for your Assistance.

      1. Thank you for all the assistance. It work perfectly in SharePoint. My next task is to remove the same characters from the Send Email V2. that I’m sending as a confirmation.

  3. Hi Mark!

    This is an excellently written solution for single incoming items. I’m inheriting an old SharePoint list which is approaching the 5000 limit. My goal is creating a purge that moves all list records over 90 days to an excel sheet stored in a file container so as not to lose historical data. I have everything working except the columns with multiple choice checkbox arrays. I can’t seem to find a solution that achieves this… do you happen to know how to achieve this? I would gladly send you screenshots of what I have working and I and my associate have worked on a solution by scouring the web and brainstorming for 2 days. (One of which was a 12 hour day of NOTHING but trying to solve this…) In any case I appreciate anything you might offer to help.

    -Thank you,

  4. Hi Manuel,
    I get the following error when trying this (for a selected file in SP adding some options as inputs to the corresponding multi select column).
    Unable to process template language expressions in action ‘Removes_the_Characters’ inputs at line ‘1’ and column ‘2515’: ‘The template language function ‘replace’ expects its first parameter ‘string’ to be a string. The provided value is of type ‘Array’. Please see https://aka.ms/logicexpressions#replace for usage details.’. Any ideas?

    1. Hi Cheryl,

      For some reason, the function is getting an array as the first element. Is the item in the “body(‘Get_response_details’)?[‘….’]” (the field in the Form) is the choice field?

      You can remove the “body….” from the formula and select from the list your own and Power Automate will complete with the data.

      Please take care also that the “Get response details” is the same form as the trigger.

      Can you please check if and let me know if you have any questions?


  5. Great walk through, thank you. When I get to the sharepoint entry, the array variable defined “ValueToInsert” is not an option. Only “current item” and “outputs,” which are both wrong of course. I double checked all of the entries. Thoughts?

    1. Hi Max,

      Indeed it’s not an option. It’s a string formatted as a JSON array.
      This is necessary so that SharePoint can “understand” the mapping and add the columns correctly.

      Are you getting errors on your side? I’m happy to help if you, please provide me the error you’re getting.


Leave a Reply

%d bloggers like this: