So you are using the RemoteObject protocol to get your data?  Do you
know for a fact that the data service is not returning xml?  Have you
tried changing the resultFormat?

Tracy

 

________________________________

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of j_lentzz
Sent: Tuesday, February 12, 2008 6:30 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: How to expand nodes down in trees

 

Additional info, the result format is "object", not "e4x", so I don't
seem to have the parent call to work with - it is null. I'm not sure
what is required on the servlet side (java) to use a different format.
I was given this to work with and didn't write the servlets.

Thanks for any help,

John
--- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
, "Tracy Spratt" <[EMAIL PROTECTED]> wrote:
>
> Do it the other way around. Find the nodes you want displayed, then
use
> xml.parent() to climb up the ancestor chain, expanding nodes as you
go.
> I have a simple example on www.cflex.net <http://www.cflex.net/
<http://www.cflex.net/> > .
> 
> 
> 
> Tracy
> 
> 
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
[mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
] On
> Behalf Of j_lentzz
> Sent: Tuesday, February 12, 2008 4:28 PM
> To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com> 
> Subject: [flexcoders] How to expand nodes down in trees
> 
> 
> 
> Hi,
> 
> I have an app where I need open up the nodes of a tree to display a
> node chosen through a search text. For example, if I type 'flex' in
> the search box, I need to display all the nodes that have 'flex' in
> their label. This means that I need to open all the parent nodes down
> to that node. I'm using flex 2, so I can't use any new Flex 3
> methods. I have a routine that will recursively open up the parent
> nodes from a given node, but it needs to start at the top of the tree
> to work, so if many items are found it gets very slow. I'd like to do
> it in a single pass. I can identify the nodes I want to display by
> searching through the XMLList from calling
> XMLListCollection(this.dataProvider).descendants(); Is there a way to
> use this structure to determine the trail of nodes to open without
> having to start at the top of the tree and recurse for each item?
> 
> Thanks,
> 
> John
>

 

Reply via email to