web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / The new modern Combo B...
Power Apps
Unanswered

The new modern Combo Box selectedItems errors out

(0) ShareShare
ReportReport
Posted on by

Hi Guys

I have been following Raza recent tutorial Power Apps PATCH function Tutorial with Modern Controls. But the Skills: combo multiselect control error's out. The data source is SharePoint. It is definitely the selectedItems property the issue, just wondered if there is a workaround or syntax I am missing here.

 

I been struggling a bit with this one...

 

bllknight007_1-1700584094960.png

 

Thanks in advance  

Categories:
I have the same question (0)
  • Hassan_SZ_365 Profile Picture
    542 on at

    Hi @bllknight007 ,

    Use this Formula:

     

    Patch(
     'Employee Data', 
     If(varRecordType="New", Defaults('Employee Data'), varItem),
     {
     Title: TextInputCanvas1.Text,
     Department: DropdownCanvas2.Selected,
     Age: Value(TextInputCanvas2.Text),
     'Hire Date': DatePickerCanvas1.SelectedDate,
     'Exit Date': DatePickerCanvas2.SelectedDate,
     Salary: Value(TextInputCanvas3.Text),
     Skills: ForAll(ComboboxCanvas1.SelectedItems, {Value: Value}),
     Active: CheckboxCanvas1.Checked
     }
    )

     

    In this formula, ForAll(ComboboxCanvas1.SelectedItems, {Value: Value}) creates an array of records with a Value field, which is the format expected by SharePoint for multi-select choice fields.

    If you still encounter issues, make sure the names of the controls (ComboboxCanvas1, TextInputCanvas1, etc.) match exactly with those in your app. Also, ensure that the column names (Skills, Title, Department, etc.) match with the internal names of your SharePoint list's columns.

    If the Skills column is a 'Lookup' column in SharePoint, the approach would be different, and you would have to use the Id of the selected items.

    Best Regards,
    Hassan Raza

  • MudassarSZ365 Profile Picture
    591 on at

    Hi @bllknight007 ,

    corrected version of the Skill field patching:

    Skills: ForAll(ComboboxCanvas1.SelectedItems, {Value: Value})

    Patch function with correction

    Patch(
     'Employee Data',
     If(varRecordType="New", Defaults('Employee Data'), varItem),
     {
     Title: TextInputCanvas1.Value,
     Department: DropdownCanvas2.Selected.Value,
     Age: Value(TextInputCanvas2.Value),
     HireDate: DatePickerCanvas1.SelectedDate,
     ExitDate: DatePickerCanvas1_1.SelectedDate,
     Salary: Value(TextInputCanvas2_1.Value),
     Skills: ForAll(ComboboxCanvas1.SelectedItems, {Value: Value}),
     Active: CheckboxCanvas1.Checked
     }
    );

      If this solution helps resolve your issue, please accept it. 😊

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 759 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 310 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 228

Last 30 days Overall leaderboard