【发布时间】:2011-02-01 21:24:12
【问题描述】:
我在数据网格的 2 个不同列上有两个项目渲染器。两者都是组合框。我在这里尝试做的是根据在 firxt 组合框中的项目选择设置第二个组合框的数据提供者。但是如何让第二个 itemrenderer 知道第一个中选择的项目是什么?
这里是代码
<mx:DataGridColumn id="deptCol" headerText="Department" width="300">
<mx:itemRenderer>
<mx:Component>
<mx:HBox width="100%" height="100%" horizontalAlign="center">
<mx:ComboBox id="cmbBox1" dataProvider="{XML(data).d.@department_description}" />
</mx:HBox>
</mx:Component>
</mx:itemRenderer>
</mx:DataGridColumn>
<mx:DataGridColumn id="deptCol" headerText="Department" width="300">
<mx:itemRenderer>
<mx:Component>
<mx:HBox width="100%" height="100%" horizontalAlign="center">
<mx:ComboBox id="cmbBox2" dataProvider="{<some DataProvider Based on Selection of cmbBox1> ?? **HOW TO SET IT**}" />
</mx:HBox>
</mx:Component>
</mx:itemRenderer>
</mx:DataGridColumn>
【问题讨论】:
标签: flash actionscript-3 flex3 adobe