We have the following:-
1) SharePoint list which have a field of type People/Group which allow multiple selection
2) Planner
now we want to loop through all the SharePoint items >> and for each item >> to create a planner task >> assign the planner task to the users defined inside the People/Group field... but i am not sure how i can implement the scenario of building a comma separated list of a SharePoint People/Group field which allow multiple selection, so i can define this comma separated list inside the Assigned User Ids's planner field:-
any advice?
Thanks
I also try this workflow:-
1) get all the SP items + initialize an array var
2) initialize string var + loop through the SP items + build an array of the assigned users' emails
3) build a comma separated var string based on the array, add the string var to the create planner task:-
but when i run the flow i got this error "The execution of template action 'Apply_to_each_2' failed: the result of the evaluation of 'foreach' expression '@items('Apply_to_each')' is of type 'Object'. The result must be a valid array.":-
any advice?
@Shujaath_Khan thanks for the info,, but i do not want to build the comma separated list for all the items.. i want to build a separate comma separated list for each item.. so the loop through the GetItems should build the comma separated list for all the users inside the item's People/Group field >> then create a planner task.. so at the end we will have a planner task for each SharePoint item, and both the item and the planner task will have the same assigned to users.. i hope this explain my case..
Hi @johnjohn123
assume you're going to get the email id's as list
and compose expression example as below
concat(items('Apply_to_each')?['Email'],';',variables('varEmailList'))
Thanks
Please click Accept as Solution on this reply if it helped to solve your issue, and thumbs-up if you feel this is useful or important in other ways as a boost.
Tomac
986
Moderator
stampcoin
699
Super User 2025 Season 2
Riyaz_riz11
577
Super User 2025 Season 2