web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Where is the Patch fun...
Power Apps
Unanswered

Where is the Patch function located when a Gallery is created using the template creator?

(0) ShareShare
ReportReport
Posted on by 4

Kind of a weird question here, but I created a Gallery using the template option, with Excel as a datasource. I am trying to find the spot where the Gallery is updated my Excel sheet.

 

The Excel updates and the Gallery works as intended, however, I don't see the code that is causing it to work correctly, lol.

 

There is a "save"/"checkmark" button which has the SubmitForm function, and a Form which has an UpdateContext function, but I dont see the Patch or UpdateIf anywhere.

 

Does anyone have any experience with the Gallery template using online Excel as a datasource and knows where the update/patch code is?

Categories:
  • MudassarSZ365 Profile Picture
    591 on at

    Hi @hp1 ,

    When you use a gallery with Excel as a data source in PowerApps, typically the data saving process is handled automatically by the data form associated with the gallery. The `SubmitForm` function is indeed what's usually responsible for sending the data back to the source, which in your case is an Excel file hosted online.

    If you have a "Save" or "Checkmark" button triggering `SubmitForm`, it's actually referring to a Form Control that handles the data input and update process. The `SubmitForm` function submits the changes made in that form to the connected data source. So, you won't necessarily see a `Patch` or `UpdateIf` function because the `SubmitForm` function is doing that job.

    The Form Control has a property called `Item` which is bound to the selected item from the gallery, and any changes made through the form are submitted back to the data source when `SubmitForm` is executed.

    To summarize, look for a Form Control connected to your gallery. The saving to Excel is done through this form when `SubmitForm` is called, not through a `Patch` function, which is why you might not find `Patch` or `UpdateIf` explicitly written in the code.
    Kindly mark the solution as accepted if it resolves your issue.

    Best Regards
    Muhammad Mudassar Mazhar

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 354 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 330

#3
Mohsin Ali Profile Picture

Mohsin Ali 232

Last 30 days Overall leaderboard