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 / update sharepoint list...
Power Apps
Unanswered

update sharepoint list person with combobox

(0) ShareShare
ReportReport
Posted on by 59

My data is a sharepoint list. It includes a "Person" type.

 

In Power Apps, I have a combobox that displays the person correctly.

The combobox also searches the persons correctly.

 

But when I want to update the collection, I have an error :


UpdateIf(
    colGridUpdates,
    ID = ThisItem.ID,
    {
        Titre: txtTitle.Value,
        Description: dpDescription.Value,
        'Due Date': dpDueDate.SelectedDate,
        Priority: {Value: dpPriority.Selected.Value},
        Auteur: {Value: combobox_usagers.Selected}
    }
)

 

 

Error here :

combobox_usagers.Selected

 

It says "Expecting a record value, but of a different schema."

 

"combobox_usagers.Selected.Value" does not work either.

 

How can I send a "Record" type back to Sharepoint ?

 

 

Categories:
I have the same question (0)
  • Ami K Profile Picture
    15,689 Super User 2024 Season 1 on at

    @trogne -

     

    The answer will depend on what you have in the Items property of your "combobox_usagers" ComboBox control, and whether the person column in your SharePoint list is single-select or multi-select.

     

    As a start however, have you tried:

     

    Auteur: combobox_usagers.Selected

     

  • james1994 Profile Picture
    231 Moderator on at

    Hey @trogne,

     

    The error is occurring because you are patching a record with the field "Value" into that Person column. 

    combobox_usagers.Selected.Value would not work either as that will return text, where you need to provide a record.


    What is the data for your combo box? Does the data source have an email column? If it's a list of your AD, you could just use:

     

    Auteur: combobox_usagers.Selected

     

    If that doesn't work, then you can refer to Matthew Devaney's blog post on how to patch a person type column:

    PATCH A SharePoint Person Column In Power Apps - Matthew Devaney

     

    Specifically, you'd need to patch the person column with a record containing Claims data (assuming your combo box is able to return an email for a selected record):

     

    UpdateIf(
     colGridUpdates,
     ID = ThisItem.ID,
     {
     Titre: txtTitle.Value,
     Description: dpDescription.Value,
     'Due Date': dpDueDate.SelectedDate,
     Priority: {Value: dpPriority.Selected.Value},
     Auteur: {
     '@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
     Claims: $"i:0#.f|membership|{combobox_usagers.Selected.Email}",
     Department: "",
     DisplayName: "",
     Email: "",
     JobTitle: "",
     Picture: ""
     }
     }
    )

     

     

     

     

     

     

  • trogne Profile Picture
    59 on at

    This line seems misplaced :

    {Value: combobox_usagers.Selected}

     

  • james1994 Profile Picture
    231 Moderator on at

    Yes, that was something I had forgotten to remove. Apologies.

  • trogne Profile Picture
    59 on at

    Thanks James,

    Can you have a look at :

    https://powerusers.microsoft.com/t5/Building-Power-Apps/confusion-over-a-collection-not-getting-cleared-because-of-one/td-p/2646802

     

    For my combobox "Items" property, instead of using :

    Filter(
    	Office365Users.SearchUserV2(
    		{
    			searchTerm: Trim(Self.SearchText),
    			isSearchTermRequired: false
    		}
    	).value,
    	AccountEnabled = true && Not("#EXT" in UserPrincipalName)
    )

     

    I now just use  Choices(Tasks.Auteur).

     

    That way, in my UpdateIf, I can simply have "Auteur: combobox_usagers.Selected".

     

    But as you will see, I have a very strange behavior : my "update" collection does not get cleared!

     

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 356 Most Valuable Professional

#2
11manish Profile Picture

11manish 225 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 211

Last 30 days Overall leaderboard