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 People fields...
Power Apps
Unanswered

Patching People fields and attachments not working

(0) ShareShare
ReportReport
Posted on by 475

Hello All,

 

hope you are all doing good....and hope someone will be able to help me

 

I have a form linked to a SharePoint list. Since i customized some fields, i have to use a Patch in order to save the form.

This form contains multiple fields but includes 3 people fields (multiple selection enabled) and the user also needs to save attachments.

 

I collect my users to 3 collections at the very top of the OnSelect of my "Save" button. After this i have the Patch function ...

 

 

// Same kind of function to collect users from the 2 other fields
ForAll(
 UserExpertValue.SelectedItems,
 Collect(
 CollUserExpert,
 {
 '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
 Claims: "i:0#.f|membership|" & ThisRecord.Email,
 Department: "",
 DisplayName: ThisRecord.DisplayName,
 Email: ThisRecord.Email,
 JobTitle: ".",
 Picture: "."
 }
 )
);

// Saving data to the list
Patch(
 MyList,
 First(
 Filter(
 MyList,
 ID = Value(IDValue.Text)
 )
 ),
 {
 Title: TitleValue.Text,
 Country: CountryValue.Selected,
 'Instrument Type': InstrumentTypeValue.Selected,
 'Confidential Service': ConfidentialServiceValue.Value,
 GDPR: GDPRValue.Selected,
 'Root Cause of service': RootCauseValue.Text,
 'New or Existing Business': NewExistingBusinessValue.Selected,
 
 //copying the selected users to a text field - keeping the existing content
 ContactsTxt: ContactsTxtValue.Text & Concat(
 CollContacts,
 DisplayName & " "
 ),
 RiskContactTxt: RiskContactTxtValue.Text & Concat(
 CollRiskContacts,
 DisplayName & " "
 ),
 UserExpertTxt: UserExpertTxtValue.Text & Concat(
 CollUserExpert,
 DisplayName & " "
 )
 },
 //Used to save the attachements
 MyListForm.Updates
);

 

 

Keeping the formula this way was working for the last 3 months and now it suddenly doesn't anymore.

 

Trying to find a solution,  I moved the user saving part (at the bottom of the Patch) to a new Patch function that i put between the 2 parts of the formula (right before the Patch) . this was collecting my users, adding them to my list but resetting all the other changes on my form so i had to do them again and the data was finally saved.

 

then i got everything back and removed the attachment line (at the bottom of the patch) to put it after the Patch function in another Patch but also without any Patch. here...a strange behaviour again. while in my personal environment, everything works but shows an "unknown error"  when i recreate this at work, it shows no error but it doesn't work at all.

 

so i really don't know what happens and how to solve this.

I just want to save data, people and attachments from a form into my SharePoint list....

 

does anyone have an idea what happens and how i could solve this please ?

 

Thanks a lot for your help.

 

 

Categories:

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
11manish Profile Picture

11manish 395 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 260 Most Valuable Professional

Last 30 days Overall leaderboard