Reputation: 11
The SAP standard controls which can display large aggregations (like tables) only bind and render a small number of items at a time. When the user scrolls down the list the then visible items are rendered. The number of rendered lines at a time are usually limited to 100.
I have not found any examples/documentation yet about the prptocol between the control and the data binding system to rerender the next chunk of items when the user wants to scroll.
As a workaround my own control contains the following overloaded bindAggregation method:
bindAggregation: function(sKey,oBindingInfo)
{
if (!oBindingInfo.length) oBindingInfo.length=50000; // Max number of lines to display
return sap.ui.core.Control.prototype.bindAggregation.apply(this,arguments); //call superclass
}
In addition my control uses overflow attributes to show scrollbars. It works but when the datasource is large performance suffers because all thousends of UI5 controls and DOM elements for the items are rendered.
Has anybody an example how to build a "dynamic" rendering like the table control is doing?
Upvotes: 1
Views: 885
Reputation: 360
Perhaps create some events in your control that can trigger the next batch. The following links might be usefull:
Creating additional triggers to load more data
Upvotes: 1