求助,像下面的xml字符串,如何在flex里显示出树形结构 - Web 开发 / 其他
<?xml version="1.0" encoding="gbk"?><RootNode><Node> <StructureID text="91"/> <StructureName text="标题"/> <Node> <StructureID text="94"/> <StructureName text="子标题"/> </Node></Node><Node> <StructureID text="97"/> <StructureName text="致谢"/> <Node> <StructureID text="100"/> <StructureName text="子标题"/> <Node> <StructureID text="101"/> <StructureName text="子标题"/> <Node> <StructureID text="102"/> <StructureName text="子标题"/> <Node> <StructureID text="103"/> <StructureName text="子标题"/> </Node></Node></Node></Node></Node><Node> <StructureID text="98"/> <StructureName text="文摘"/></Node><Node> <StructureID text="99"/> <StructureName text="标题"/></Node></RootNode>
<mx:XMLList id="treeData" xmlns=""> <RootNode> <Node StructureID="91" StructureName="标题"> <Node StructureID="94" StructureName="子标题"> </Node> </Node> <Node StructureID="97" StructureName="致谢"> <Node StructureID="100" StructureName="子标题"> <Node StructureID="101" StructureName="子标题"> <Node StructureID="102" StructureName="子标题"> <Node StructureID="103" StructureName="子标题"> </Node> </Node> </Node> </Node> </Node> <Node StructureID="98" StructureName="文摘"> </Node> <Node StructureID="99" StructureName="标题"> </Node> </RootNode></mx:XMLList> <mx:Tree id="myTree" width="100%" height="100%" labelField="@StructureName" showRoot="false" dataProvider="{treeData}"/>
[解决办法]
顶个,来接点分
希望早日解决