Hi everyone,

I'm building my first one-framed dynamic XML website, which can be updated using this FlashXMLeditor.
All of my content gets populated from 1 XML file.

One of the submenu's is a Tree component with several buttons (=nodes).
When pressing one of these nodes of this Tree, I want to show some detailed information (text) and load several images of the selected node.
How do I do this???

The Tree itself gets populated correctly, but the changeListener doesn't work.
I don't want to use node.attributes because then the XMLeditor doesn't work for me.

This is my AS so far:

PHP Code:
//Tree menu uit XML laden
graphicXML = new XML();
graphicXML.ignoreWhite true;
graphicXML.onLoad = function (success){
    if (
success){
        
tofillTreeGraphicdesign();
    }
    else{
        
trace("The XML could not be loaded");
    }
}
graphicXML.load("content/content-test.xml");


function 
tofillTreeGraphicdesign(){
    
graphicdesign.vScrollPolicy "off";
    
graphicdesign.rowHeight 18;
    
graphicdesign.setStyle("fontSize"8);
    
graphicdesign.setStyle("fontFamily""Bavaria Regular");
    
graphicdesign.setStyle("fontWeight""normal");
    
graphicdesign.embedFonts true;
    
graphicdesign.setStyle("selectionColor"0xFFFFFF);
    
graphicdesign.setStyle("textSelectedColor"0x000000);
    
//We filled the menu
    
graphicdesign.dataProvider graphicXML.firstChild.childNodes[1].childNodes[0];
    
//event objectss
    
graphicdesign.addEventListener("change"listChanged);
}

listChanged = new Object();
listChanged.change = function(evt_obj) {
    var 
node evt_obj.target.selectedNode;
    
//If it is a folder…
    
if (graphicdesign.getIsBranch(node)){
        
//If this is a branch, expand/collapse it.
        
if (graphicdesign.getIsOpen(node)){
            
graphicdesign.setIsOpen(nodefalsetrue);
        }
        
//We opened it if this closed 
        
else {
            
graphicdesign.setIsOpen(nodetruetrue);
        }
    }
    
//If it is a bond…
    
else {
        
test._visible false;
        
        var 
Client node.childNodes[0];
        var 
Year node.childNodes[1];
        var 
Medium node.childNodes[2];
        var 
Desc node.childNodes[3];
        var 
Img node.childNodes[4];
        
        
client.text Client;
        
year.text Year;
        
medium.text Medium;
        
description.xmltext.text Desc;
        
loadMovie(Img"_root.picholder");
    }

And my XML file:

PHP Code:
<?xml version="1.0" encoding="utf-8"?>

<content>

    <personal>
        
        <vision name="Vision">
            <bodytekst>Tekst voor Vision
            </bodytekst>
         </vision>
         
         <work name="Work">
             <bodytekst>Tekst voor Work</bodytekst>
         </work>
         
         <downloads name="Downloads">
             <node label="Download 1" dirurl="download1.pdf" />
         </downloads>
         
    </personal>
         
    <projects>
         
         <graphic name="Graphic design">
         
             <node label="Graphic 1">
                 <client>Client</client>
                 <year>2007</year>
                 <medium>website</medium>
                 <desc>Omschrijving</desc>
                 <image>images/image_1.jpg</image>
             </node>
         
         </graphic>
         
         <spatial name="Spatial design">
            <node label="Spatial 1"/>
         </spatial>
         
         <other name="Other works">
             <node label="Other work 1"/>
         </other>
    
    </projects>
    
    <network>
    
        <communities name="Communities">
            <node label="community 1" dirurl="http://www.domain.nl" />
        </communities>
        
        <clients name="Clients">
            <node label="client 1" dirurl="http://www.domain.nl" />
        </clients>
        
        <contacts name="Contacts">
            <node label="contact 1" dirurl="http://www.domain.nl" />
        </contacts>
    
    </network>
    
</content>
Could someone please push me in the right direction?
I tried using a seperate .as file to load mx.controls.tree, but I can't figure out how that works.

I could really use some help, because I'm on a deadline ont his project.
Many many thanks!