This content has been marked as final. Show 3 replies
I'm not quite sure I am understanding your question. Are you trying to set the labelField to something variable, or are you trying to make a custom item renderer?
It is easy to change the displayed labels on the Tree nodes using labelFunction().
But, the tree wants to show the same structure as the dataProvider xml. It is not simple to have it do otherwise, though you might look into creating a custom DataDescriptor.
I would just process the xml to make it the format the tree needs.
The problem is when the value is between xml tags ( <node>value</node>) the node name gets folder icon and value gets doc. icon.
With lot of last elements, one has to click every node to see the values.
With labelFunction every leaf gets null value:
If hasComplex return localname
Return localname + children
When I try to pars xml to new one, hasChildren returns true for las element, and if there is no value the node shows null.
Then walking the xml recursively how do I insert the nodes in new xml with the same structure but tags like (<node data=”value” />)? (to XMLListCollection)
Hope it’s clearer