0 Replies Latest reply on Feb 3, 2009 6:14 PM by GSS1

    Calling a custom function with node data as string parameter

    GSS1 Level 1
      Hi,

      I have an xmllist for my flex tree. When a new node is selected, I want to load a text file and display it in the textbox which is on the right.

      I have this code: "ReadFile()" in my tree object. The constructor takes a string parameter which I want to be the path of the file, specified in data, eg: <node label="Thread" data="2"/>

      How can I pass in the data element of the clicked node to the readfile function call?

      Also, I have some parent nodes like so:

      <node label="Custom Project" data="10">
      <node label="Thread" data="2"/>
      <node label="MSN Logging" data="3"/>
      <node label="eCommerce - Product" data="0" isBranch="true" />
      <node label="Composite Design Pattern" data="5" />
      </node>

      and single nodes like: <node label="" data=""/>

      How can I ensure that on only inner and individual single nodes (therefore not a parent node), this function is called with the data object as a string?

      Thanks