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 / Gallery/Multiple Check...
Power Apps
Unanswered

Gallery/Multiple Checkbox - Selected Values

(1) ShareShare
ReportReport
Posted on by

Hello,

 

I have a SharePoint PowerApps form which has a gallery control which has a checkbox. I have converted a SharePoint choice column to a checkbox with multiple selections. I am trying to toggle the visibility of another datacard based on the checkbox values selected.

I tried CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) but it doesnt seem to work.

How else can I do this? Please note that I need to toggle on load of the form in EditMode too.
 
Thanks.
Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,968 Moderator on at

    Hi @PowerSuiteUser 

     

    CountRows Returns a number, so you would need to say

     

    If(CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) > 0, true, false) for visible

     

    If(CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) > 0, DisplayMode.Edit, DisplayMode.View) for Display

     

    If(CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) > 0, FormMode.Edit, FormMode.View) for Display


    If I have helped you, I would really appreciate if you please Mark my answer as Resolved/Answered, and give it a thumbs up, so it can help others

    Cheers

    Thank You
    Michael Gernaey MCT | MCSE | MCP | Self-Contractor| Ex-Microsoft
    https://gernaeysoftware.com
    LinkedIn: https://www.linkedin.com/in/michaelgernaey

  • PowerSuiteUser Profile Picture
    on at

    Hi,

    CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) returns 0 for me even if multiple checkbox values are selected so I am not able to proceed any further to try your suggestions.
     
    Thanks.
  • DarogaBabu Profile Picture
    24 on at

    Hi,

     

    I am fairly new to Power Apps and had a similar use case. So, I am expecting it to be the same.

     

    What I understand is that you have a gallery and a connected edit form.  Now, within the gallery you have multiple checkboxes which when checked will make the datacard visible in the edit form.

     

    You can try using OR, AND in the Visible property of the datacard. Something like this:

    Or(And(Checkbox1.Value,Checkbox2.Value),Checkbox3.Value)

     

    I apologize in advance if I got a different understanding.

  • Michael E. Gernaey Profile Picture
    53,968 Moderator on at

    Then change it to add them all,

    its a separate call for it

     

    If(
    CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)) > 0
    Or
    CountRows(Filter(Gallery1.AllItems,Checkbox2.Value)) > 0
    Or
    CountRows(Filter(Gallery1.AllItems,Checkbox2.Value)) > 0
    
    , 
    
    
    true, false) for visible
  • PowerSuiteUser Profile Picture
    on at

    Hi,

     

    Your solution wouldnt work for me as I get a 0 for CountRows(Filter(Gallery1.AllItems,Checkbox1.Value)).

    I have updated my original question to reflect the actual requirements.

     

    Thanks.

  • PowerSuiteUser Profile Picture
    on at

    Thanks for your suggestion. I have updated my original question. I have a single checkbox with multiple values based on a SharePoint choice field, inside a  gallery control.

  • Michael E. Gernaey Profile Picture
    53,968 Moderator on at

    Put pictures on the screens, no words, it really helps people trying to help you and understand so as not to waste time

  • PowerSuiteUser Profile Picture
    on at

    PowerSuiteUser_0-1720214652625.png

     

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 325 Most Valuable Professional

#2
11manish Profile Picture

11manish 165

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 88 Super User 2026 Season 1

Last 30 days Overall leaderboard