cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Morghan
Helper IV
Helper IV

Custom form intermittently showing error

Hello,

 

I have a custom form built via PowerApps in a SP List and it intermittently displays the following error when hitting "New." I can hit the "x" to close it and everything works fine, it's just alarming to users who have never seen it before. Why is this popping up?? "The requested operation is invalid. Server Response: Item does not exist. It may have been deleted by another user."

 

powerapps-error.jpg

 

 

I have tried completely deleting the custom form and rebuilding again. I am using a Create form, an Edit form and a View form, all using the following formulas in the "SharePointIntegration" section (source: https://powerapps.microsoft.com/en-us/blog/separate-custom-forms/) --

 

OnNew – Set(SharePointFormMode, "CreateForm"); NewForm(CreateItemForm); Navigate(CreateScreen, ScreenTransition.None)

OnEdit – Set(SharePointFormMode, "EditForm"); EditForm(EditItemForm); Navigate(EditScreen, ScreenTransition.None)

OnView – Set(SharePointFormMode, "ShowForm"); ViewForm(ShowItemForm); Navigate(ShowScreen, ScreenTransition.None)

OnSave – If(SharePointFormMode="CreateForm", SubmitForm(CreateItemForm), If(SharePointFormMode="EditForm", SubmitForm(EditItemForm)))

OnCancel – If(SharePointFormMode="CreateForm", ResetForm(CreateItemForm), If(SharePointFormMode="EditForm", ResetForm(EditItemForm)))


Is it possibly something with these formulas that are causing the error?? I cannot pinpoint what's going on. It's very intermittent. I have also turned off this option below which I've been advised may help, no avail: 

 

powerapps-1.jpg

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @Morghan ,

Based on the issue that you mentioned, I have made a test on my side, and don't have the issue that you mentioned.

 

Please consider modify your formula as below:

OnNew :

Refresh('YourSPList'); // Add this formula
Set(SharePointFormMode, "CreateForm");
NewForm(CreateItemForm);
Navigate(CreateScreen, ScreenTransition.None)

OnEdit:

Refresh('YourSPList');  // Add this formula
Set(SharePointFormMode, "EditForm");
EditForm(EditItemForm);
Navigate(EditScreen, ScreenTransition.None)

OnView:

Refresh('YourSPList'); // Add this formula
Set(SharePointFormMode, "ShowForm");
ViewForm(ShowItemForm);
Navigate(ShowScreen, ScreenTransition.None)

 

In addition, please also check if you have specified other formulas in your app, e.g. Patch function, to do some CRUD opeation to your SP List data source.

 

Also please consider take a try to turn on the "Formula-leave error managments" option within "Advanced settings" of App settings of your app, then re-publish your app, check if the issue is fixed.

 

Please consider take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-xida-msft
Community Support
Community Support

Hi @Morghan ,

Based on the issue that you mentioned, I have made a test on my side, and don't have the issue that you mentioned.

 

Please consider modify your formula as below:

OnNew :

Refresh('YourSPList'); // Add this formula
Set(SharePointFormMode, "CreateForm");
NewForm(CreateItemForm);
Navigate(CreateScreen, ScreenTransition.None)

OnEdit:

Refresh('YourSPList');  // Add this formula
Set(SharePointFormMode, "EditForm");
EditForm(EditItemForm);
Navigate(EditScreen, ScreenTransition.None)

OnView:

Refresh('YourSPList'); // Add this formula
Set(SharePointFormMode, "ShowForm");
ViewForm(ShowItemForm);
Navigate(ShowScreen, ScreenTransition.None)

 

In addition, please also check if you have specified other formulas in your app, e.g. Patch function, to do some CRUD opeation to your SP List data source.

 

Also please consider take a try to turn on the "Formula-leave error managments" option within "Advanced settings" of App settings of your app, then re-publish your app, check if the issue is fixed.

 

Please consider take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Good morning,

 

Thank you for the prompt response and assistance! I have not been able to replicate that issue since turning on the "Formula-leave error" option you mentioned. Thanks again! 

 

Morghan

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 (6,073)