|
Well I’m closer but no cigar yet. I can
get the dataProvider to update with the checkbox click, but each checkbox click
requires 2 clicks! One to get focus in the box and one to actually change the
checkbox…and I can’t figure out how to center the Checkbox now since it’s not
in an HBox anymore. <mx:DataGrid width="100%"
height="80%" id="resultsDG"
dataProvider="{searchService.result.hospitals.hospital}"> <mx:columns> <mx:Array> <mx:DataGridColumn
editorProperty="selected" textAlign="center" columnName="compare"
sortable="false" headerText="Compare" width="75"
isCellEditor="true"> <mx:cellRenderer> <mx:Component> <mx:CheckBox
selected="{dataObject.compare}"/> </mx:Component> </mx:cellRenderer>
</mx:DataGridColumn> <mx:DataGridColumn
textAlign="center" cellRenderer="nameRenderer"
columnName="name" headerText="Hospital Name"/> <mx:DataGridColumn
textAlign="center" columnName="distance"
headerText="Distance" width="100"
id="distance"/> <mx:DataGridColumn
textAlign="center" cellRenderer="swfRenderer"
columnName="quality" headerText="Quality"
width="100"/> </mx:Array> </mx:columns> </mx:DataGrid> _________________________________________ Jonathan Miranda Flexible Master of the Web "In the
game of chess, it's important to never let your opponent see your pieces." From: There are CellRenderer's
and CellEditors. A cell renderer just adjusts the display from the
default textinput to a checkbox etc... However, if you change the
cellrenderer, that won't have any affect on the underlying dataprovider. You
need to set the cellrenderer's isCellEditor property to true. This will
cause the cell to use the cellRenderers class as the editor class as
well. Once you have a cellEditor, you have access to the underlying
dataprovider. On 2/6/06, Jonathan
Miranda <[EMAIL PROTECTED]>
wrote: So
I decided to mess around with the new inline cell-renderers…and having issues
getting at their data. Pretty simple example… <mx:cellRenderer> <mx:Component> <mx:HBox width="100%"
horizontalAlign="center"> <mx:CheckBox
id="myCheckie"/> </mx:HBox> </mx:Component> </mx:cellRenderer>
</mx:DataGridColumn> _________________________________________ Jonathan Miranda Flexible Master of
the Web "In the game of chess, it's important to never
let your opponent see your pieces."
SPONSORED
LINKS
YAHOO!
GROUPS LINKS
|
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- Re: [flexcoders] New Inline cell renderers Manish Jethani
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- Re: [flexcoders] New Inline cell renderers Manish Jethani
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- Re: [flexcoders] New Inline cell renderers Manish Jethani
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda
- RE: [flexcoders] New Inline cell renderers Matt Chotin
- RE: [flexcoders] New Inline cell renderers Jonathan Miranda

