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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patching Combo Box who...
Power Apps
Unanswered

Patching Combo Box whose items = Office365Users.SearchUser({searchTerm:Self.SearchText,top:999}) which is a multi select to Share Point list column named 'business sponsor' which of person or group type and is multi select

(0) ShareShare
ReportReport
Posted on by 8

Patching Combo Box whose items = Office365Users.SearchUser({searchTerm:Self.SearchText,top:999}) which is a multi select to share point list column named 'business sponsor' which of person or group type and is multi select.

please tell me the code for this. 

I am also facing one more issue that I am able to patch the combo box items to share point list column and when I click on edit button on the gallery it hovers me to the edit form , but now when I click on submit button , it does patch the already selected values of my people picker combo box, rather it will only patch the values when I reselects the new values in the combo box.

please provide me the correct code for the implementation.

I have the same question (0)
  • v-jefferni Profile Picture
    Microsoft Employee on at

    Hi @upadharp ,

     

    You can use blow code for the Person column in Patch function:

    ForAll(
     ComboBox.SelectedItems As PP, 
     {
     Department: "",
     Claims: "i:0#.f|membership|" & PP.Mail,
     DisplayName: PP.DisplayName,
     Email: PP.Mail,
     JobTitle: "",
     Picture: ""
     }
    )

     

    Best regards,

  • upadharp Profile Picture
    8 on at

    ForAll(
    Edit_BusinessSponsor_ComboBox.SelectedItems,
    {
    Claims:ThisRecord.Mail,
    Department:"",
    DisplayName:ThisRecord.DisplayName,
    Email:ThisRecord.Mail,
    JobTitle:"",
    Picture:""} // Replace with the appropriate property name
    )
    i have used this to patch, but when i am clicking on edit button in my gallery , it takes me to the edit form screen, now if i do not update the business sponsor combo box that is i keep it as it is without changing any selected values, and click on submit the business sponsor column in the sharepoint list do not get filled with any values and it is empty.

  • v-jefferni Profile Picture
    Microsoft Employee on at

    Hi @upadharp ,

     

    This is because the DefaultSelectedItems of Combo box doesn't match the Items of the Control. You should set it as below:

     

    ForAll(ThisItem.sponsor As SP, LookUp(Office365Users.SearchUser({searchTerm:SP.Email,top:999}), Mail = SP.Email))

     

     

    Best regards,

  • upadharp Profile Picture
    8 on at

    what property to be set to this code? for the Business Sponsor combo box i have two properties :-
    Items: Office365Users.SearchUser({searchTerm:Self.SearchText,top:999})

    defaultselecteditems:Parent.Default // as i am using a form

    onselect(submit button):Patch(
    File,
    LookUp(File, Title= Edit_ProjectID_Text_Input.Text),
    {
    Title:Edit_ProjectID_Text_Input.Text,
    'Business Sponsor': ForAll(
    Edit_BusinessSponsor_ComboBox.SelectedItems,
    {
    Claims:ThisRecord.Mail,
    Department:"",
    DisplayName:ThisRecord.DisplayName,
    Email:ThisRecord.Mail,
    JobTitle:"",
    Picture:""} // Replace with the appropriate property name
    )

    please tell me where to edit the code , it would be of great help

  • v-jefferni Profile Picture
    Microsoft Employee on at

    It's the DefaultSelectedItems property.

     

    Best regards,

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 1,033

#2
Valantis Profile Picture

Valantis 632

#3
11manish Profile Picture

11manish 607

Last 30 days Overall leaderboard