cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
smcb123
Helper I
Helper I

ETAG mismatch when saving form - possibly related to setting variables that are the defaults for sharepoint fields

Hi,

 

I'm currently getting a ETAG mismatch error when trying to save a form. I will get it once, though if I click the save button again it will allow me to save and update the record correctly. 

smcb123_1-1634649074403.png

 

I have read about adding a refresh of the data source before submitting the form, however this will give me a 'data source may be invalid' error.

smcb123_2-1634649136620.png

 

The form itself has multiple sections that may become available when data is entered and saved. There aren't any problems saving until I get towards the end of the form where I've added functionality that updates some of the previously entered fields. Within a dropdown list attached to a sharepoint field, I have the following in the onChange section:

 

Set(varS10or28A,{Value:"28A"});

Set(varRecStatus,{Value:"Draft"});

Set(varLevel,{Value: ""});

Set(varForm,{Id:1,Value: "28A - learning (made at the end of a case)"}),

 

These variables are set as the defaults for other fields within the form. The first three are attached to choice fields, whilst the 'varForm' is attached to a lookup field. I populated the items for the form field with a collection that I created by filtering on the choices of the field. I noticed while looking at the collection that there was an Id field, so I included it whilst setting the variable.

 

I also have multiple combo boxes that I have in place to duplicate some of these fields. After the previous change has been made there is a combo box (ComboBox2) within a custom card that has a Default\DefaultSelectedItems of varLevel and the following within onChange:

 

Set(varLevel,ComboBox2.Selected)

 

This is in place, so the user doesn't have to navigate back to a previous section to update the field. All these steps work correctly, the fields in question are populated with the desired items and they will eventually save correctly, however the issue is that I get this error message.

 

Can anyone think what the issue might be?

 

Thanks,

 

Stephen

 

1 REPLY 1
kssymssy
New Member

This is exactly the situation I am experiencing right now. Anyone has explanation on this? I never changed anything on code my code for a long time then just one day the ETAG mismatch suddenly occurred. Tried adding the Refresh() then encountered the data source may be invalid error.

Helpful resources

Announcements
Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Super User 2 - 2022 Congratulations

Welcome Super Users

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

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Government Carousel

New forum: GCC, GCCH, DoD - Federal App Makers (FAM)

In response to the unique and evolving requirements of the United States public sector, Microsoft has created Power Apps US Government.

Users online (2,329)