I need to run a Patch on the OnChange function in a Gallery.
The column that needs patching will change depending on what item in the gallery is selected.
I have tried this formula, that seems logical to me, but does not seem to work:
Patch(Master_Data,LookUp(Master_Data,LO_ID = drpLearnObj.Selected.LO_ID),{ThisItem.Criteria_ID: txtScore_1.Text})
You'll see the part 'ThisItem.Criteria_ID:' - this is drawing from a separate data source and used to select the column to patch depending on the gallery item. The text of 'ThisItem.Criteria_1' matches the text of the column I'm trying to patch.
But it doesn't like it.
If I replace this with an individual column name ('Criteria_1:' for example), that patch works. But I only want this column patched on the first item in the gallery. The second item needs to patch Criteria_2 etc.
Any help is appreciated!
Andy