cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Select All Button In Gallery CheckBox

Hi everyone,

 

I'm very new to this development. I would like to ask about how to develop a button that can select all checkbox inside the gallery.

 

Please help me

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Okay I found the solution :

 

1. Insert a new input called "CheckBox" 

2. Change CheckBoxOption Default property into Checkbox1.Value=true

 

Everything is done 🙂

View solution in original post

9 REPLIES 9
eka24
Super User
Super User

You can look at this tutorial. May give a good start.
https://youtu.be/Jc_JLxMqtFs

If you like this post, give a thumbs up. Where it solved your issue, Mark as a solution
Anonymous
Not applicable

Okay I found the solution :

 

1. Insert a new input called "CheckBox" 

2. Change CheckBoxOption Default property into Checkbox1.Value=true

 

Everything is done 🙂

v-yutliu-msft
Community Support
Community Support

Hi @Anonymous ,

Do you want to make all the check boxes unchecked or checked in a gallery by clicking a button?

I've made a similar test for your reference:

1)set the checkbox's Default:

var

2)set the checked button's OnSelect:

Set(var,true)

3)set the Unchecked button's OnSelect:

 

Set(var,false)

 

2142.PNG

 2143.PNG

 

Then, if you click the checked button, all the check boxes will be checked.

If you click the Unchecked button, all the check boxes will be Unchecked.

 

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

But at my side, this only makes all the checkbox visually checked. The OnCheck event won't be triggered. Would you mind sharing a way to use a button to trigger all the OnCheck events? Thanks!

raph2
Frequent Visitor

any update to trigger all the items elements selected ? @v-yutliu-msft 

Anonymous
Not applicable

Actually I'm using a "Select All Checkbox". To realize the visual effect, just use the method mentioned in the accepted solution. To "Select" all the items, use "ForAll(Gallery.AllItems,Collect(SelectionList,Item));".  

isolight6
Frequent Visitor

@raph2  have you found a solution for that?

Thanks. This thing works and checks all the checkboxes at a time. But after that, I want to delete the data attached with those checkboxes and it's not happening when all boxes are selected.

Simple, yet profound.

Helpful resources

Announcements
October Events

Mark Your Calendars

So many events that are happening this month - don't miss out!

Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Top Solution Authors
Top Kudoed Authors
Users online (2,519)