No announcement yet.
  • Filter
  • Time
Clear All
new posts

  • Append a node to a collapsed TreeGrid and have the node displayed

    I am using SmartClient_v111p_2017-09-16_LGPL with IE11.

    In the TreeGrid, I am trying to append a node to a collapsed tree and have the TreeGrid display the appended node. The problem I am having is opening the path to the appended node.

    function Append_onClick(btn) {
        // the following function, AppendTree, does append a new node to the Tree
        var newLocn = AppendTree(_isoConfigTree);
        // the LGPL function getParent is working,
        //        but the openAll does not display an open path to the node: newLocn
        // the following lines are to make sure the node is visible to the user, I think they will work
        var displayedAt = _isoConfigTree.getRecordIndex(newLocn);
        if (displayedAt >= 0)
    Any suggestions as to where I went wrong?


  • #2
    openAll() opens all folders under a given node. So what you've done here would open the immediate parent of newLocn, as well as any folders that are peers of newLocn, but wouldn't open any intervening parents.

    A correct approach would be getParents() then openFolders().