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 uncheck a check...
Power Apps
Unanswered

How to uncheck a checkbox by another checkbox, inside gallery control ?

(0) ShareShare
ReportReport
Posted on by 18

Hi,

 

I have a gallery control and I have added a checkbox in it and now I have one situation, that is :

 

I need to uncheck a checkbox when I select any one checkbox.

For e.g. I have 10 checkbox and I check first checkbox then I am filtering my table by the text of that checked checkbox . Now I have checked another checkbox in gallery then deselect the first one and table will be filtered by the 2nd checked checkbox's text.

Categories:
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @trickytechie,

    Sounds like you need to use a radio control.

  • trickytechie Profile Picture
    18 on at

    Hi @Drrickryp,

     

    No. I cannot use radio buttons. My requirement is for multiple selection (Only checkbox)

  • v-monli-msft Profile Picture
    Microsoft Employee on at

    Hi @trickytechie,

     

     

    You mentioned that you need multiple selection, but then your requirement is to auto-uncheck all other options when one option is selected. This is paradoxical.

     

    Or did I misunderstand your requirement? Did you mean that you want to filter the Gallery according to your   selections? No matter with single selection or multiple selections? If so, then actually this is exactly what Radio and ComboBox control do. 

     

    If we use the combo box, and you want to filter the gallery according to multiple items selected in combo box, then the formula of filtering with combo box should be something like:

    Filter(
    datasource,
    First(LastN(ComboBox1.SelectedItems,1)).Value in ChoiceColumn && First(LastN(ComboBox1.SelectedItems,2)).Value in ChoiceColumn && First(LastN(ComboBox1.SelectedItems,3)).Value in ChoiceColumn && ... )

     

    If you insist to use the multiple separated checkboxes, and your column is multiple-selected column, then I do not think this could be achieved so far.

     

    Regards,

    Mona

     

  • PStafford Profile Picture
    21 on at

    Hey! I realize I'm five years late on this one, but I came across this same issue and somehow found a solution. 

     

    In the "OnVisible" property of the screen the checkboxes are on, add this: 

    UpdateContext({varCheckboxes:Blank()});

     

    Then on your first checkbox, set the "OnCheck" property to: 

    UpdateContext({varCheckboxes:"Checkbox1"});

    Set the "OnUncheck" property to: 

    UpdateContext({varCheckboxes:Blank()});

     And then set the "Default" property to: 

    varCheckboxes="Checkbox1"

     

    And do the same on the other checkbox(es) with just the number changed.

     

    PStafford_2-1689878609124.png

     

    PStafford_0-1689878334060.png

    PStafford_1-1689878358505.png

    cbexample.gif

     

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

#2
M Bilal Khan Profile Picture

M Bilal Khan 271

#3
Mohsin Ali Profile Picture

Mohsin Ali 223

Last 30 days Overall leaderboard