I'm creating a form that allows users to select and edit an existing item from a gallery, using the Navigate/Edit Form functions in the OnSelect field of a button in the gallery, and the Gallery.Selected function in the Item field on the form.
However, I'd also like to be able to select and edit items via the underlying SharePoint list, as with SharePointIntegration.Selected function. Currently, I can only edit the form if I go through the gallery. If I try to select an item from the list, it gives me the item I last opened in the gallery instead of what I actually selected.
How can I include both edit options?
Consider using a variable for your Gallery selection.
Set the OnSelect formula to include: Set(glbCurrentRecord, ThisItem)
Then change your Item property of your form to:
Coalesce(glbCurrentRecord, SharePointIntegration.Selected)
The gallery selection will then show if it is selected and if nothing is selected, then the integration selected record will show.
If you need to at some point revert back to the integration record after a gallery item is selected, then simply put a Set(glbCurrentRecord, Blank()) where ever it is appropriate.
I hope this is helpful for you.
User | Count |
---|---|
250 | |
105 | |
82 | |
51 | |
43 |