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

Community site session details

Session Id :
Power Apps
Unanswered

Error in Patching

(0) ShareShare
ReportReport
Posted on by
Hi. I have a "Employee Involved" dropdown, I want that when I edit it and add person it will patch successfully. But the scenario is I need to remove the previous value first and then re-select again the persons to be able for patching to be successful.




 
EmployeeInvolved: If(
                CountRows(employeeInvolvedComboBox_2.SelectedItems) <> CountRows(varEditConcern.EmployeeInvolved) || !IsEmpty(
                    Filter(
                        employeeInvolvedComboBox_2.SelectedItems,
                        IsBlank(
                            LookUp(
                                varEditConcern.EmployeeInvolved,
                                DisplayName = DisplayName
                            )
                        )
                    )
                ),
                ForAll(
                    employeeInvolvedComboBox_2.SelectedItems,
                    {
                        '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpanderUser",
                        Claims: "i:0#.f|membership|" & Lower(Mail),
                        DepartmentOfInvolved: Department,
                        DisplayName: DisplayName,
                        Email: Lower(Mail),
                        JobTitle: JobTitle,
                        Picture: "."
                    }
                ),
                varEditConcern.EmployeeInvolved// Retain previous values if no new selection or no change
            )
           


 
Categories:
I have the same question (0)
  • Suggested answer
    Nandit Profile Picture
    1,568 Moderator on at
    Error in Patching
     
    Is there a reason why you are removing the values from your Combobox first before adding new persons? Is that a requirement?
     
    Also what is the Items property of your Combobox?

    I have created a Combobox in my Test app and tried to build something similar - 
     
    Items property of the Combobox (Cmb1):
    Choices(DataSource.EmployeeInvolved)
    DefaultSelectedItems:
    varEditConcern.EmployeeInvolved
     
    Patch Button (Can also use the OnChange property)
    Patch(
        DataSource,
        varEditConcern, // the selected record
        {EmployeeInvolved: Cmb1.SelectedItems}
    )
    I have also added a Reset button to go back to the default values:
    Reset(Cmb1)
    This is how it looks and it works perfectly. 
     
    Hope this helps. 
     
    Kind regards, 
    Nandit

    If this answers your query, please mark this response as the answer.
    If its helpful, please leave a like. Thanks!
  • Nandit Profile Picture
    1,568 Moderator on at
    Error in Patching
    Hi,

    Following up to check if you were able to solve this issue using my suggestion?

    Kind regards,
    Nandit

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 836 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 231 Super User 2025 Season 2

Last 30 days Overall leaderboard