I followed Reza Dorrani's guidance on creating a multi-select choice checkbox control connected to a SharePoint list.
Multi Select Checkbox in Power Apps - YouTube
I am not building an app, but just customizing a SharePoint form. The Update action is acting very strangely. There are two multi-select choice columns in the form. If I update one of them and not the other, only the one that updates saves the existing selected values. I cannot figure out why. It seems that the collection variable for the control is not getting populated, so if no values are actively selected during an update, it sets the values to blank because the variable is empty.
I have the variables populating (supposedly) in the OnVisible action of the FormScreen. I just modified Reza's formulas to not include the clearing of the variable since it is blank when the form opens.
OnVisible
Collect(colLocations, LocationGallery.Selected.Value);
Collect(colProducts, ProductGallery.Selected.Value);
This seems to work as the "Default" property for each multi-select choice card is set to the variable and the values are populated when the form is opened. But as mentioned previously, if I update any other fields on the form, but not the multi-select fields, their values get set to null. All existing selections are lost. If I make changes to a multi-select field, the field then updates properly, including preexisting selections. The Update property for each multi-select choice card is also set to the appropriate variable as indicated in Reza's video. I just don't understand why the collection variable is empty when I'm populating each when the form becomes visible.
Any ideas?
Thanks!
WarrenBelz
146,635
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,997
Most Valuable Professional