Skip to Content

How to set total number of row count in growing mode sap.m.Table More button

Hi,

I am implementing growing mode sap.m.Table which consumes a odata service where there are more that 9000 records. So I do not want to load all record at once. I am loading 20 records at time. On click of More button I will load next 20 records and so on.

But as per guideline, we need to show total number of rows count below the More button(i.e; More [20/9000]).

I am able to get total number of rows count by calling service with $count. But i do not how to set this count value in table control. Can any one help?


Regards,

Vinayak.

More_Button.PNG (1.8 kB)
Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    Posted on Jul 25, 2016 at 09:19 AM

    Hi Vinayak,

    Will this sample help? Plunker

    In the above sample, it shows max records as '100' (I have hard-coded to that value to show how you can change the number) but there are only 14 records loaded on application.

    Regards,

    Sai.

    Add a comment
    10|10000 characters needed characters exceeded

    • I think it is better not to use the filters in your get method.

      Because you are saying that top='20' so the model is getting the 20 records and the model is binding to the table with 20 records and as a result it is displaying More[10/20].

      I am not sure,

      but you can try it once you may get the result.

      Thanks,

      Deepak.

  • Posted on Jul 25, 2016 at 08:34 AM

    Hi Vinayak,

    Please refer to the link How to count the number of rows in a table in s... | SCN .

    It may help you.

    Regards,
    Srinivasan

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.