Hi, I’m trying to fill my treeview with data retrieved
from a webservice. I have my resultformat set to default (Object), as e4x or
xml doesn’t give the correct result. Filling a datagrid with the data I retrieve works perfectly,
but the problem is when there are nested objects in it, the tree doesn’t
draw childNodes. This is the value of my webservice result object: event = events.DataManagerResultEvent (@2b67be6) bubbles = false : Boolean cancelable = false : Boolean currentTarget = managers.DataManager (@2b0b0b6) eventPhase = 2 [0x2] : Number result = mx.utils.ObjectProxy (@29d6e46) getCategoriesResult = Object (@2bab0a6) node = Object (@2bab8c6) node = Array (@2b672b6) [0] = Object (@2baba66) catID = 15 [0xf]
: Number label =
"Pixco Labs" : String [1] = Object (@2babc26) catID = 1 [0x1] :
Number label =
"Technology" : String node = Array
(@2b671c6) [0] =
Object (@2babe06) catID
= 6 [0x6] : Number label
= "ASP.NET" : String [1] =
Object (@2b9c046) catID
= 7 [0x7] : Number label
= "HTML/CSS" : String [2] =
Object (@2b9c246) catID
= 8 [0x8] : Number label
= "_javascript_" : String [3] =
Object (@2b9c426) catID
= 9 [0x9] : Number label
= "SQL" : String [4] =
Object (@2b9c606) catID
= 10 [0xa] : Number label
= "Tech Experiments" : String [5] =
Object (@2b9c7e6) catID
= 16 [0x10] : Number label
= "Flash/Flex/Flash Lite" : String length = 6
[0x6] : Number [2] = Object (@2b6fa06) catID = 2 [0x2] :
Number label =
"Utilities" : String node = Array
(@2b67376) [0] =
Object (@2babf66) catID
= 11 [0xb] : Number label
= "Client tools" : String [1] =
Object (@2babd66) catID
= 12 [0xc] : Number label
= "Server tools" : String length = 2
[0x2] : Number [3] = Object (@2babb86) catID = 3 [0x3] :
Number label =
"Design" : String node = Array (@2b676d6) [0] =
Object (@2bab966) catID
= 13 [0xd] : Number label
= "Cool layouts" : String [1] =
Object (@2bab386) catID
= 14 [0xe] : Number label
= "Design experiments" : String length = 2
[0x2] : Number [4] = Object (@2c62e26) catID = 4 [0x4] :
Number label =
"Usability" : String [5] = Object (@2c62286) catID = 5 [0x5] :
Number label =
"Off-topic" : String length = 6 [0x6] :
Number xmlns = 0 [0x0] : Number object = Object (@2bab1a6) uid =
"F97D8CAC-0C05-4ED5-3B1FFFFFFFFF090A" : String xmlns = "http://tempuri.org/" :
String target = managers.DataManager (@2b0b0b6) type = "getCategoriesResponse" : String The tree only renders the nodes in the root, it doesn’t
create the subNodes. Do I need to loop through this data in code? It would be a
lot easier if I could just put this result as the dataSource for my tree. Thanks for any suggestions, -- 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] Objects and arrays as treeview datasource Jonas Windey