cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Pxtavern
Helper II
Helper II

"Network error when using patch function: The requested operation is invalid." Error has popped up after weeks of working

Hi all

 

I have a gallery that connects to SharePoint list. I have an "Approve all on call" button that approves all items within that gallery. It has been working for weeks flawlessly but now it suddenly gives the error: "Network error when using patch function: The requested operation is invalid." every single time. I have no idea what's causing it as the code shows as correct and has not been changed since it was working. Can anyone help? The "Onselect" Property of the button is as follows:

ForAll(ReviewerGalleryOncall.AllItems,
Patch(
'OCR Calendar',
First(
Filter(
'OCR Calendar',
StatusChoice.Value = "Sent for Manager Review",
Team.Value = LookUp(
'OCR Teams',
Reviewer.Email = User().Email
).'Team Name'
)
),
{
ManagerApprovalStatus: {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
Id: 0,
Value: "Approved"
},
ManagerApprovedBy: {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims: "i:0#.f|membership|" & User().Email,
Department: "",
DisplayName: User().FullName,
Email: User().Email,
JobTitle: "",
Picture: ""
},
ManagerApprovedOn: Now(),
StatusChoice: {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
Id: 2,
Value: "Approved by Manager"
}
}
)

)

 

 

The gallery items property is as follows:

 

With(
{
wTeam:
LookUp(
'OCR Teams',
Reviewer.Email = User().Email
).'Team Name'
},
SortByColumns(
Filter(
'OCR Calendar',
StatusChoice.Value = "Sent for Manager Review" &&
Team.Value = wTeam
),
"Title"
)
)

 

 

No errors show for either. Any help is very much appreciated 

The error.PNG

onselct part 2.PNG

onselect code part 1.PNG

  

items code.PNG



4 REPLIES 4
rbunge
Advocate V
Advocate V

Hi @Pxtavern -

 

Any updates to this? We're in exactly the same position -- working fine for months, then this today. Extremely frustrating.

 

Turned out to be an update issue with Powerapps. After a few days working with a support rep powerapps updated and it worked. Try reverting to a previous powerapps version ( not app version) 

rbunge
Advocate V
Advocate V

Brilliant -- thanks very much, and quick reply is much appreciated. Will check version and revert to previous engine.

 

Cheers!

dionmar
New Member

@Pxtavern Hi, Am facing the same problem!!!!!

 

Doesn any one tried to back engine PowerApps version!? 

tks so much! 

Helpful resources

Announcements
Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

<
Users online (4,018)