I'm new to PowerApps
I'm building a form which which populates a sharepoint list with some data. Among other things on my form i have 2 combo box people pickers, one for Owner which allows the selection of 1 person and one for members which allows multiple selections.
The Owners combo box has the following in the Items property
Office365Users.SearchUser({searchTerm:cb_Owner.SearchText})
While Members has the following
Office365Users.SearchUser({searchTerm:cb_members.SearchText})
I have a button which posts the data to sharepoint with the following OnSelect
Collect(
MSTSFormList,
{
Title: Label1.Text,
TeamType: DD_TeamType.Selected.'Template id',
Owner: {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims: "i:0#.f|membership|" & Lower(cb_Owner.Selected.Mail)
},
Members: Table( {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims: "i:0#.f|membership|" & Lower(cb_members.Selected.Mail)
}
)
}
)
Everything else works works fine however I'm struggling to get members to work. All it does is output the last person that was entered in the the members box, instead of all of them. This does make sense to me as I can see I need to put multiple entries in the table section of the collect, however I'm unsure how to go about this. I've been looking at using ForAll or possibly creating variables that I could put here but I can't figure it out.
Any help would be appreciated.
Thanks!