
Announcements
Hello!
I have a gallery with various items. On each line, I have a checkbox to select it from, and I also have a checkbox that selects all the lines. I need to create a lock so that when I reach 299 selected lines, I won't let any more be selected.
How to do this?
Place a label outside of your Gallery (you can set the Visible to false as this is just a helper label) and set the Text property to: CountRows(Filter(yourGallery.AllItems, yourCheckBox.Value))
Set the DisplayMode of your gallery checkbox to :
If(Value(theLabelNamefromAbove.Text)>=299 && !Self.Value, Disabled, Edit)
You are done!
This will disable all unchecked checkboxes while leaving the checked ones available in case the user wants to uncheck one.
I hope this is helpful for you.