I played around with this a little today and realized that RemoteObject doesn't support returning a Document class too nicely because the Document implementations (at least the default crimson version) have circular references.  This is something we can look to fix in a future updater.  In the meantime the question is whether you really want the data represented as XML in the first place.  If you are pulling in the data from a database you can simply build a tree of objects and return that to Flex.  Flex can take those objects and build a tree out of it as long as you specify the labelField correctly.  If you already have XML then I guess what you can do is serialize it into a String, send that across to Flex, then turn that String back into XML using mx.utils.XMLUtil.createXML().

 

Let me know if this doesn't make sense,

 

Matt

 

-----Original Message-----
From: brian_r_christian [mailto:[EMAIL PROTECTED]
Sent: Sunday, May 09, 2004 11:46 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Populating a Tree at Runtime with a org.w3c.dom.Document

 


What I'm trying to do is get a org.w3c.dom.Document from a method of
a remote POJO and populate an mx:Tree with its results.  How would
this work?  The POJO method seems to work fine, but we're not sure
how to get the returned org.w3c.dom.Document into a format that the
Tree will display.

Thanks!

Brian Christian



Reply via email to