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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Interactive Checkboxes...
Power Apps
Answered

Interactive Checkboxes within Gallery

(0) ShareShare
ReportReport
Posted on by 14

Hello all,

 

Couldn't find any information on this question in the forum so appreciate any feedback. I have two different checkboxes each within its own gallery. The checkboxes contain the days of the week. I was hoping to make it so that if I selected two days in the first gallery that it would grey out those two days from the second gallery. For example, if I choose Monday & Tuesday in the first checkbox then I would not be able to select those two days in the second checkbox.

 

Potentially unrelated information, the checkboxes are populated by a list within square brackets. I am using a hidden label to count the number of checkboxes selected. So if I select two days then the rest of the days are disabled within the checkbox.

 

Please let me know if you need any additional information and thank you for your time.

Categories:
I have the same question (0)
  • Verified answer
    RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @gonzalesbarrett 

    Sure!

    Set your Items property of the Galleries to:  Calendar.WeekdaysLong()

     

    Then set your CheckBoxes Text properties to: ThisItem.Value

     

    In the second gallery, set the DisplayMode property to:

    If(
     !LookUp(Gallery1.AllItems, Checkbox1.Text=ThisItem.Value && Checkbox1.Value, true), 
     DisplayMode.Edit, 
     Disabled
    )

    Where Checkbox1 is the checkbox in the first gallery.  Change as needed.

     

    I hope this is helpful for you.

  • gonzalesbarrett Profile Picture
    14 on at

    Hey Randy thank you for the quick response.

     

    That seems to disable the entire second checkbox. Is there a way to only disable the specific days that have been selected in the first checkbox so those days cannot be selected in the second checkbox, but other days still can? Ideally the goal is two select two days from the first checkbox, remove those two days from the second checkbox, and then still be able to select two different days in the second checkbox?

     

    Attached a poorly edited photo below to try and get my point across :). 

    Thank you again for your time.

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @gonzalesbarrett 

    Yes, that is what I provided you should be doing.

    gonzalesbarrett.gif

    Did you apply the DisplayMode formula I provided to the CheckBox in the second gallery?  Looks like you might have put it in the first.

     

  • gonzalesbarrett Profile Picture
    14 on at

    @RandyHayes,

     

    Hmm not sure what I am doing wrong but the now it says "ThisItem" isn't recognized. I made sure I put your formula in the second gallery. Fairly certain I followed the rest of your instructions correctly I keep going through to verify and everything else seems right.

     

    Thanks again

     

    Edit: I got it had the formula in the gallery not the checkbox I misread. My apologies thank you so much 

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @gonzalesbarrett 

    Good deal!  Yes, needed on the Checkbox in the Gallery.  Controls in the Gallery will all have a ThisItem available to them.  Anything *at* the gallery level or above will not have a ThisItem available.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard