【发布时间】:2011-12-05 07:33:10
【问题描述】:
我的数据网格中有一个复选框作为 itemRenderer。我正在从我的数据库表的列中设置选定的值。变量的值为“true”,但我的复选框被选中,尽管我将其 selected 属性设置为 true 的数据字段。
我的代码如下:
<mx:DataGrid id="myGD" fontSize="9" enabled="true" x="20" y="20" width="217" height="60">
<mx:columns>
<mx:DataGridColumn rendererIsEditor="true" editorDataField="selected" width="20" headerText="isDefault" dataField="IS_DEFAULT">
<mx:itemRenderer>
<fx:Component>
<mx:HBox horizontalAlign="left">
<s:CheckBox selected="{Boolean(data['IS_DEFAULT'])}" horizontalCenter="0"/>
</mx:HBox>
</fx:Component>
</mx:itemRenderer>
</mx:DataGridColumn>
</mx:columns>
</mx:DataGrid>
有人可以帮助我了解这里出了什么问题吗? 非常感谢
【问题讨论】:
标签: datagrid checkbox flash-builder itemrenderer