Tree refreshItem() not working

I am loading a tree hierarchy via an XML fetch to my server. When the user does something to alter the tree, I want to refresh the tree by calling:


where ‘xxx’ is the id for the main root of the tree.

When I invoke this, I get a javascript exception on this line:
TypeError: str.indexOf is not a function

Note: I have tried with no parameters with the same result.

What am I doing wrong (besides choosing the wrong career :slight_smile: )?

refreshItem works only in dynamic trees and uses script that is defined in the setXMLAutoLoading method as xml source. Here is the sample … fresh.html

Another approach to reload tree is:


Thank you, the alternate approached worked :slight_smile: