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 / Repeating Gallery - Pa...
Power Apps
Answered

Repeating Gallery - Patching Collection

(0) ShareShare
ReportReport
Posted on by

Hi,

 

I have a gallery whose contents can be edited by the user. The gallery is patches to a collection with a button, that is inserted per gallery row which is simply coded like this:

 

Patch(TestCollection, ThisItem, {My Value: Label.Text})

 

 

Is there anyway I can create button to loop through all "ThisItems" in the gallery to patch to the collection all at once, so that users do not have to click the save button each time, per row?

 

Thanks!

Categories:
  • Verified answer
    WarrenBelz Profile Picture
    156,538 Most Valuable Professional on at

    Hi @shuhn1229 ,

    Do you have thr ID of the record in the gallery or some other unique identifier ?

    Patch(
     TestCollection, 
     ForAll(
     GalleryName.AllItems as aGal,
     { 
     ID: aGal.ID,
     'My Value': aGal.Label.Text
     }
     )
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • shuhn1229 Profile Picture
    on at

    figured out exactly this with some trouble shooting, thank you @WarrenBelz 

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 405 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 368

#3
WarrenBelz Profile Picture

WarrenBelz 244 Most Valuable Professional

Last 30 days Overall leaderboard