Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Panel header text should display total number of rows in sap.m.table


I was able to read number of rows in a table for which data is coming from Odata entityset.If I try to set panel header text , initially it is not displaying count.

If I try to display from on init () method , it is displaying as 0 count as odata might not be generated by the time table loads. I tried the same code in different hook methods but no luck.

Is there any different method which I can use to display total number of rows count on table header during first time loading.

If there is anymethod to calculate the count from entityset , please share the sample code as well.

I used below code to set Panel headertext from onSelectionChange method.

    var mytab=this.getView().byId("testTable");

    var count = mytab.getItems().length;




Koti Reddy

Former Member

Hello Koti and Dennis,

Here is a version of your discussion and code using an XML View,

Panel Header Text Row Count

Hope this helps,


2 View this answer in context

Helpful Answer

Not what you were looking for? View more on this topic or Ask a question