title: UI5 Tree Table expanded node list
body: <p>I Have a <a href="https://openui5.hana.ondemand.com/#docs/api/symbols/sap.ui.table.TreeTable.html" rel="nofollow noreferrer">tree table</a> Where i need to get the expanded nodes</p>
  <p>right now i have code to take the rowIndex which are expanded</p>
  <pre><code>&lt;table:TreeTable selectionMode=&quot;MultiToggle&quot;
      enableSelectAll=&quot;false&quot; rowHeight=&quot;40&quot; 
      toggleOpenState=&quot;onOpenParent&quot;
  </code></pre>
  <p>Controller i have the code as below</p>
  <pre><code>onOpenParent : function(oControlEvent)
        {
            var rowIndex = oControlEvent.getParameter('rowIndex');
            ....
  </code></pre>
  <p>Which will tell the rowIndex which are open.</p>
  <p>Problem:</p>
  <p>When the treemodel is changed the rowIndex are not valid for example i have 10 rows, after some thing the tree model is changed and became only 5 rows.</p>
  <p>if i have rowIndex as 7 which is expanded the 7 is invalid now because we have only 5 rows.</p>
  <p>So need to clear these index if it reaches invalid state. OR i need to take the expanded nodes after rendering.</p>
  <p>Which is better way and HOW?</p>