title: Get table row count in SAPUI5
body: <p>I have an <code>sap.ui.Table</code> that shows a list of records. I want to get a count of the records in the data.</p>
  
  <p>I have read the post <a href="https://stackoverflow.com/questions/25113076/sap-ui-5-how-to-print-total-table-row">SAP UI 5 how to print total table row</a> , but it hasn't helped me.</p>
  
  <p>This is the code for the table (code for the columns has been removed to make the post smaller):</p>
  
  <pre><code>  &lt;table:Table id="PickRecs" visibleRowCount="10" selectionMode="MultiToggle" visible="true" rows="{/downRecs}" &gt;
      &lt;table:title&gt;
          &lt;txt:Text text="{
        path: '/downRecs',
        formatter: 'Formatter.totalFormatter'
      }"&gt;
          &lt;/txt:Text&gt;
          &lt;Label text="possible records to export"&gt;&lt;/Label&gt;
  
      &lt;/table:title&gt;
      &lt;table:columns&gt;
        .......
      &lt;/table:columns&gt;
   &lt;/table:Table&gt;
  </code></pre>
  
  <p>This is the formatter.js:</p>
  
  <pre><code>totalFormatter:function(results) {
  
      return results.length;
   }
  </code></pre>
  
  <p>I would like to display how many rows there are in the table using the array <code>downRecs</code> as the source of all the records. For example: 3 possible records to export.</p>
  
  <p>This value can change based on some input fields on the screen, for example they can choose to see all records for a product or only records for a certain customer, etc.</p>
  
  <p>How can I get this updated count of the records? This value is shown on the toolbar or title of the table.</p>