cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JackP
Frequent Visitor

Manage number of displayed rows dynamically

Hi,

 

I have a question regarding managing number of displayed rows in gallery for example. 

 

Let's say that we managed delegation warnings and everything works fine. We used sorting, and filters, etc. rules, and the number of records displayed in the gallery are ok. After some time the number of rows in the database increased by another let's say 5000 - 10000 lines. So now our filter and sorting rules are not handling delegation issues.

How do manage this kind of situation? How to dynamically avoid delegation issues?

 

One of my ideas is to set rows counter, and set arrows icons so that after displaying the first 0-500 items user would be able to click and display the next set 501-1000. 

 

Thank you in advance for your help.

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @JackP ,

Firstly, when a Delegable query returns results in a Gallery, it only does so 100 at a time (this is invisible to the user) and scrolling down loads the next 100 until all records are displayed. You can find out the number loaded at any time with CountRows(GalleryName.AllItems), but you cannot say "load the next 500" as they will still come 100 at a time and there is no trigger on the gallery scrolling (so you cannot detect when the user does this)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

View solution in original post

1 REPLY 1
WarrenBelz
Super User
Super User

Hi @JackP ,

Firstly, when a Delegable query returns results in a Gallery, it only does so 100 at a time (this is invisible to the user) and scrolling down loads the next 100 until all records are displayed. You can find out the number loaded at any time with CountRows(GalleryName.AllItems), but you cannot say "load the next 500" as they will still come 100 at a time and there is no trigger on the gallery scrolling (so you cannot detect when the user does this)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (4,783)