【发布时间】:2011-11-26 13:58:06
【问题描述】:
伙计们,
我在 ActionScript 中有以下 xml。
var xml:XML = <Top>
<Component>
<type>Button</type>
<id></id>
<width>50</width>
<height>20</height>
<x>0</x>
<y>0</y>
</Component>
<Component>
<type>Label</type>
<id></id>
<width>30</width>
<height>10</height>
<x>0</x>
<y>0</y>
</Component>
</Top>;
现在,我想读取/解析这个 xml 字符串,然后根据它们各自的属性生成 Flex 控件(即按钮、标签)。
如何做到这一点?
谢谢。
【问题讨论】:
标签: xml arrays flash actionscript-3 apache-flex