0 Replies Latest reply on Mar 26, 2007 12:16 PM by kwyjibo12ret

    writing back to an imported xml file

      Dear every1, i am having a bit of a problem. Im an actionscript amateur so my knowledge is limited.

      I have imported an xml file into my flash program with the xml_conn.trigger(); command. which is shown below.

      <node label="car">
      <node label="car size" feedback=""/>
      <node label="car shape" feedback=""/>
      <node label="car colour" feedback=""/>

      I am able to write a comment in a text area (instance name: "txtArea"). And press the "submit" button to attach that comment to the relevant node using the actionscript code below:

      feedback.onRelease=function () {

      //listener object for tree
      var lo:Object = new Object();//a object called "lo" is created.
      lo.change = function(evtObj:Object):Void {
      var itm:Object = tree.getSelectedItem();
      if(itm.savedComment != undefined)
      comment.text = itm.savedComment;
      comment.text = "";

      //listener object for submit button
      var lo2:Object = new Object();
      lo2.click = function(evtObj:Object):Void{
      var itm:Object = tree.getSelectedItem();
      itm.savedComment = comment.text;


      All i need now is for the comment added to be saved into the xml file. Possible in the "feedback" area in the xml file. So that next time i run the flash program the originally added comment is saved within and shows up when i click on that node.

      At the present moment when i click on the node and attach a comment, the comment is not displayed if i exit the swf. file and re-enter. Really need help with this as i want my comment to be displayed even after i have exited and re-entered the swf. file

      However i have no idea how to use this. really stuck any help is much appreciated.
      Text Text