Hi Everyone,
This question has been asked numerous times, but I get a weird error and none of what I'm trying works.
First, this simple Patch function works great:
Patch(Requests, Defaults(Requests),
{
Title: "Increment (TBD)",
Comments: "A",
Updates: "B",
Barcode: "",
'Manufacturer Name': ""
}
)
You can see there is no errors:
![2023-01-26 11_27_33-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png 2023-01-26 11_27_33-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png](/_api/msdyn_richtextfiles%2800660F39-7780-4AD6-B6F0-42F8628381A4%29/msdyn_imageblob/$value?size=full)
When I click on my Submit button, it sends the requests to SharePoint (SP) and I can see the new record created.
In my SP List, I have another column called "Requestor" of type "Person or Group", and it only allows the selection of a single user, and only people (no group).
Issues come when I add that column in the Patch function:
Patch(Requests, Defaults(Requests),
{
Title: "Increment (TBD)",
Comments: "A",
Updates: "B",
Barcode: "",
'Manufacturer Name': "",
Requestor:
{
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims: "i:0#.f|membership|test@test.com",
Department: "",
DisplayName: "",
Email: "",
JobTitle: "",
Picture: ""
}
}
)
I copy/pasted the syntax from other posts or blogs such as PATCH A SharePoint Person Column In Power Apps - Matthew Devaney.
Now I get errors:
![2023-01-26 11_22_00-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png 2023-01-26 11_22_00-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png](/_api/msdyn_richtextfiles%28E0ED3ECD-92C6-4585-AF40-8D5890AA6184%29/msdyn_imageblob/$value?size=full)
I tried to only keep the @OData and the claims properties, I tried reordering the properties... Still getting the same errors.
I also tried another syntax using the Office 365 User connector:
Requestor: First(Office365Users.SearchUser({searchTerm: "test@test.com"}))
but when I do that, I get other errors:
![2023-01-26 11_25_29-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png 2023-01-26 11_25_29-Power Apps and 25 more pages - [InPrivate] - Microsoft Edge.png](/_api/msdyn_richtextfiles%28543C93E1-31FB-422E-9E65-FD2A59F4E9EF%29/msdyn_imageblob/$value?size=full)
Power Apps authoring version: 3.23012.17
I am not sure what's wrong with this but I can't find a solution. Does anyone know how to solve this?
Thanks,
Matt