What does NodoArbol look like?

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of pepe_perez_perez_perez
Sent: Thursday, March 30, 2006 3:59 AM
To: [email protected]
Subject: [flexcoders] Tree hanging the virtual machine

Why this hangs the VM when clicking the button?.

Thanks,

Pepe.

<?xml version="1.0" encoding="iso-8859-1"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"; xmlns="*">

    <mx:Script>
        import NodoArbol;
        import mx.controls.treeClasses.*;

        [Bindable]
        public var raiz : NodoArbol;
        public var nodo1 : NodoArbol;
        public var nodo2 : NodoArbol;
        
        public function clickAgregarHijos() : void
        {
            raiz = new NodoArbol();
            raiz.label = "Raiz";

            nodo1 = new NodoArbol();
            nodo1.label = "Nodo 1";
            nodo1.data = "Datos 1";
            raiz.children.addItem( nodo1 );

            nodo2 = new NodoArbol();
            nodo2.label = "Nodo 2";
            nodo2.data = "Datos 1";
            nodo1.children.addItem( nodo2 );
        }
    </mx:Script>

    <mx:Tree id="arbol" height="200" width="200" dataProvider="{raiz}"
/>

    <mx:Button id="boton" label="Agregar hijos"
click="clickAgregarHijos()"/>

</mx:Application>






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links



 




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to