Altering No of records loaded programmatically

I have several use cases where I want to limit the number of Accounts and Sales Records loaded from a model initially but then allow a User to be able to change these numbers (without altering filters) … if there any way to change the default number.

Good question.

For clarity, are you wanting to first bring in only 20 records on a model at page load but then have the user change the number from 20 to 40 or 60 or whatever? Is that what you’re asking? If so, could you provide the use case as well? Knowing the business need can sometimes present an alternative method.

Hi David

With JavaScript you’re able to get the model. On the model theres a property called recordsLimit. If you change that and afterwards query the model, it will load the additional records.


Hmmm … the best UX is to have the recordsLimit value be controlled and set prior to page load by the user. That’s not something currently possible without some level of hacking.

Jannik’s method works just fine.

I’m assuming it’s per user and the # of records to load on page load.

Then, since there’s no place to store this value at the moment, then I’d create a field on the user record, update/add a page for user preferences, load CurrentUser Model and subsequently create In-Line javascript to set RecordsLimit and query the model. Janky, but your request doesn’t have OOB option. :smiley:

Thanks guys … got it. I always limit the number of records upfront on a load but when it comes to drilling down on aggregate models it would be useful to remove this limit on occasions from the UI Appreciate the help David