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

Converting multi choice form item into multi choice field in sharepoint

Hello everyone,

 

I built a form which contains a multi choice field (A, B, C). If I try to save it in the sharepoint then then it gets to comma separated value (string representation of an array, I guess) which is entirely useless because it does not match the values defined in the sharepoint field. The proper filtering is also impossible.

 

What is the proper way to pass the selected values from a form multi choice field into the sharepoint multi choice field?

 

See the screenshots of my present configuration.

 

Thank you in advance

rgolbang

 

Definition in MS FormsDefinition in MS FormsDefinition in MS SharepointDefinition in MS SharepointPassing value from the Form into the Sharepoint field using MS FlowPassing value from the Form into the Sharepoint field using MS FlowValue saved in sharepoint AFTER the flow has runValue saved in sharepoint AFTER the flow has run

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @rgolbang,

 

I have made a test on my side and there is no any way to achieve your needs in microsoft flow currently.

 

Inserting value into a multi Choice field is not supported in microsoft flow currently.

 

If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

Best regards,

Alice

View solution in original post

15 REPLIES 15
Community Support
Community Support

Hi @rgolbang,

 

I have made a test on my side and there is no any way to achieve your needs in microsoft flow currently.

 

Inserting value into a multi Choice field is not supported in microsoft flow currently.

 

If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

Best regards,

Alice

View solution in original post

@v-yuazh-msft

@rgolbang

There is a way to do that. A tad ugly but it's doing exactly when you needed - gets multiple choices from MS Forms and then saves them into SP list into a multi-choice column (as long as choices are the same).

I gotta do some polishing and will post it here.

 

This link seems to have an easy solution but it's not working for me.

https://powerusers.microsoft.com/t5/I-Found-A-Bug/Record-Microsoft-Form-choice-response-to-the-Share...

You have any luck on this yet, would love to implement it in my flow ASAP

Thanks

@PowerGell54 Have you tried a simple solution that I linked in my post? Did it not work for you?

Honestly, it never did for me.

But I do have a different way of doing it which seems to have more logic behind it and it looks pretty simple too.

No the above didn’t work for me, any chance you could share your method with us?

Thanks

Absolutely! I'll try to post by the end of the weekend.

You absolute legend! 🙂

Deleted as I found an error, will get back to you

It is pretty cool to see how many different workarounds people can come up with 🙂

What I still don't get is what kind of trick this ;# does.

 

@v-yuazh-msft Do you think you guys might change something that will break any of these workarounds?

 

So here is my version of the workaround.

 

A flow that works needs to have these core steps:

  • initialize an array variable (1)
  • remove extra symbols from Microsoft Forms string output
  • split the previous line into an array (not the same step 1)
  • append to array variable using a formula
  • create a SharePoint list item

 

20181202_9.png

Where Initializing an array variable:

20181202_10.png

Removing extra symbols from MS Forms string output:

replace(replace(replace(body('Get_response_details')?['r5beb9c2e9e4849129d94468e3db92b7a'],'","','|'), '["',''), '"]','')

20181202_11.png

Splitting the previous compose into an array:

split(outputs('Format_form_output'),'|')

20181202_12.png

Appending to array variable using a formula:

20181202_13.png

Creating an item (in a Create Item step a Switch to input entire array option must be selected for that very multi choice field):

20181202_14a.png

Please note that if you don’t work with Microsoft Forms and already have an array of values, then the steps are just initializing an array and appending to array variable using a formula. That’s it!

 

For more details and my thought process please visit my new blog, thanks!

https://365basics.com/microsoft-flow-populate-a-multi-choice-field-in-sharepoint/

Anonymous
Not applicable

@bloodoff  I have a simple excel file that I want to import into a SharePoint list using Flow.   Some of the columns are choice fields.  Can this be simplified for an excel file or would the steps probably be the same?  

 

Thanks!

@Anonymous if you can extract chosen values from your excel and create an array of them, then there won't be any difference for you. Please try.

If any issues, Iet us know. I typically don't work with Excel files so I'll have to take a look.

Hello,

 

I followed the steps. No error when I check my flow chart. But, I keep receiving this error message when I test it. How can I resolve this?

 

"Unable to process template language expressions in action'Format_Form_Output' inputs at line '1' and column '22714': 'The template language function 'replace' expects its first parameter 'string' to be string. The provided value is of tye 'Null'. Please see https://aka.ms.logicexpressions#replace for usage details.'.

 

Please help.

@TediBear 

I managed to get it working, try this:

Create a Sharepoint Item with your form dataCreate a Sharepoint Item with your form dataApply to each on your multi choice, parse it and join with ;#Apply to each on your multi choice, parse it and join with ;#Update the item with the output of JoinUpdate the item with the output of Join

Thank you so much!!! It worked!!!

Hi @PowerGell54 ! I am trying to solve a similar issue. However in my case more that one question in the form is multiple choice and I need to map the answer to multiple choice columns in sharepoint. Any suggestions in terms of how the flow would look like for two questions with multiple choices?

Also, what steps come before the apply to each 3 box you have in your screenshot? Did you remove the extra characters? Thanks!

Helpful resources

Announcements
Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Microsoft Ignite

Microsoft Power Platform: 2021 Release Wave 1 Plan

Power Platform release plan for the 2021 release wave 1 describes all new features releasing from April through September 2021.

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (19,598)