cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
professor_proto
Frequent Visitor

"Network Error when using Patch function: The requested operation is invalid" - PowerApps Form

Hello all, I hope you are well. 

 

I am facing an issue. I currently have a drop down list connected to a "office 365 user" data connection to allow for searching within the organisation. It all seems to be working well, however when I attempt to submit this form to the SharePoint website including this field, I get this error:

 

"Network Error when using Patch function: The requested operation is invalid"

 

I have honestly felt like I've tried everything and can't manage to make it click. When I do not include that specific field in the submission, the form submits just fine leading me to believe that this is the cause. 

 

I welcome any ideas. 

 

Regards,

Professor P

1 ACCEPTED SOLUTION

Accepted Solutions

Hi again ManCat, thanks for your help so far. 

 

I've just tinkered with the form a bit and realised that the error with the 'patch' function, had been because the field (an therefore column) in the SharePoint list had been a multiple choice field, rather than a people/group field (I assume it had difficulties storing the value in a choice field). The issue is now solved, thank you 🙂

View solution in original post

5 REPLIES 5
iAm_ManCat
Super User
Super User

How are you patching the Office365User to the People field, it needs a specific format during patching for complex SharePoint fields:

PersonFieldNameGoesHere: 
   {
     '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
      Claims: Concatenate("i:0#.f|membership|",YOUROFFICE365USEREMAIL_HERE),
      DisplayName: YOUROFFICE365USERNAME_HERE,
      Email: YOUROFFICE365USEREMAIL_HERE
    }
@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


professor_proto
Frequent Visitor

Hi ManCat, thanks for your reply. 

 

I am a bit of a PowerApps newbie, could you please help me understand the code above? 

 

And this is the code I am currently using in the drop down box: 

professor_proto_0-1669894967559.png

 

Oh hey, well we all gotta start somewhere 🙂

 

So, where are you patching this data? I'd like to see the patch statement that your error is referring to.

And if you're not using a patch, and just using the form submit, then I'd like to see your datacard's Update value, as that may be pointing to the wrong thing.

 

If you could explain a bit more about where the dropdown is located [in a datacard in a form, outside a form, etc] and is there a field in your datasource that can accept that dropdown value?

 

The more information you can provide the easier it will be to help 🙂

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


Hi again ManCat, thanks for your help so far. 

 

I've just tinkered with the form a bit and realised that the error with the 'patch' function, had been because the field (an therefore column) in the SharePoint list had been a multiple choice field, rather than a people/group field (I assume it had difficulties storing the value in a choice field). The issue is now solved, thank you 🙂

Awesome, thanks for coming back and confirming, I'll mark your reply as the answer! 🙂

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,569)