Search code examples
sapui5

How to load more records of table on click of button in sapui5?


My requirement is, have a table which contains approx. 200 records.

Now when onInit() calls means on initial time of loading views and controllers, my table should show me only 15 records.

Then at the bottom of table it shows that [15 / 200] like that.

Now i have to see next 15 records so on click on same area i should see next 15 records.

How can archive this?


Solution

  • Have a look at the growing functionality of the sap.m.List. (The Table extends the List and inherits the functionality.)

    <List growing="true" growingThreshold="15">
       ...
    </List>
    

    You can find a working example in the Explored App.