try this

var xml1:XML = new XML(<node label="layers">
                                                                
                        <node label="transport">
                                                                
                                <node id="2" label="busroute" 
layergroup="transport" maxscale="26.4583862501" minscale="-
1000000000" name="busroute" type="Feature" visible="1"/>
                                                                
                                <node id="1" label="expressway" 
layergroup="transport" maxscale="1000000000" minscale="-1000000000" 
name="expressway" type="Feature" visible="1"/>
                                                                
                                <node id="3" label="railroad" 
layergroup="transport" maxscale="1000000000" minscale="-1000000000" 
name="railroad" type="Feature" visible="1"/>
                                                                
                        </node>
                                                                
                        <node id="4" label="kwang" 
layergroup="layers" maxscale="1000000000" minscale="-1000000000" 
name="kwang" type="Feature" visible="1"/>
                                                                
                </node>);
                                var xc3:XMLListCollection = new 
XMLListCollection(xml1.children());
                                
                                mx.controls.Alert.show
(xc3.length.toString(), "length");


--- In flexcoders@yahoogroups.com, "Paul Hastings" 
<[EMAIL PROTECTED]> wrote:
>
> On 9/13/06, bhaq1972 <[EMAIL PROTECTED]> wrote:
> 
> > the 'layers' property is the bit you're interested in. Its well
> >  formed xml correct? so what happens when you do
> 
> yup. i can dump it out in cf & use that xml inline w/the Tree as
> 
> >  var xml1:XML = new XML(yourReturnedObject.layers);
> 
> more or less the same thing. xml1 = "[object Object]" when i try to
> dump out whatever's in there using toXMLString() it just returns
> [object Object].
> 
> >  can u show a brief structure of this xml.
> 
> sure:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <node label="layers">
> <node label="transport">
> <node id="2" label="busroute" layergroup="transport"
> maxscale="26.4583862501" minscale="-1000000000" name="busroute"
> type="Feature" visible="1"/>
> <node id="1" label="expressway" layergroup="transport"
> maxscale="1000000000" minscale="-1000000000" name="expressway"
> type="Feature" visible="1"/>
> <node id="3" label="railroad" layergroup="transport"
> maxscale="1000000000" minscale="-1000000000" name="railroad"
> type="Feature" visible="1"/>
> </node>
> <node id="4" label="kwang" layergroup="layers" 
maxscale="1000000000"
> minscale="-1000000000" name="kwang" type="Feature" visible="1"/>
> </node>
> 
> the non-label odds & ends are supposed to be for a custom renderer 
to use.
>







--
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/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/flexcoders/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> 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