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 / How to reset chechboxe...
Power Apps
Answered

How to reset chechboxes in a gallery

(0) ShareShare
ReportReport
Posted on by 211

Hi all,

I have a gallery that is connected to a collection, in this gallery I have a checkbox in all rows. I would like to create a button (outside the gallery), when I click on it I want to reset all selected checkboxes in the gallery.

I try something as Patch(collection; Gallery.AllItems;{Selected:false}) but don't work, can you help me please?

 

Thank you

 

Categories:
I have the same question (0)
  • Verified answer
    Waegemma Profile Picture
    583 Super User 2024 Season 1 on at

    Hi @common_user ,

     

    It depends if the checkbox is connected to a field/column of the collection or not.

     

    Not connected to a field/column

     

    First add a field when you Collect the collection, and give it the default value 'false'

     

     

    ClearCollect(collection,AddColumns(YourDataSource,"SelectionField",false))

     

     

    then do the steps you would do with an existing column:

     

    Connected to a field/column  'SelectionField' (replace with your own column)

     

    Properties of the CheckBox:

    OnCheck: Patch(collection, Thisitem, {SelectionField: true})
    
    OnUncheck: Patch(collection, Thisitem, {SelectionField: false})
    
    Default: Thisitem.SelectionField
    
    

     

    Properties of ResetButton

     

    OnSelect: UpdateIf(collection,true,{SelectionField: false})

     

     

    Hope this helps,

     

    Marc

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

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 326 Most Valuable Professional

#2
11manish Profile Picture

11manish 168

#3
sannavajjala87 Profile Picture

sannavajjala87 75 Super User 2026 Season 1

Last 30 days Overall leaderboard