Hi every one,

I am creating a DataGrid on the fly.
To this DataGrid i am using custom itemRenderer to display checkbox.

Problem:
I am unable to catch the check/uncheck the checkbox from out side the
custom itemRenderer.

Code:

// Creating DataGrid Column:
             var column:DataGridColumn = new
DataGridColumn( dataField );
                column.headerText = "Submit";
                column.draggable = false;
                column.sortable = false;
                column.headerWordWrap = true;
                column.editable = false;
                column.width = 90;
                column.itemRenderer = new ClassFactory( checkBoxAssignment );


// Custom checkbox itemRenderer ( checkBoxAssignment.mxml ).

<?xml version="1.0" encoding="utf-8"?>
<mx:CheckBox xmlns:mx="http://www.adobe.com/2006/mxml";
horizontalCenter="0" verticalCenter="0" paddingLeft="37" >
        <mx:Script>
                <![CDATA[

                        import mx.controls.Alert;
                        import mx.controls.dataGridClasses.DataGridListData;

                        [Bindable] private var formattedValue:Boolean;

                        override public function set data(value:Object):void
                        {
                                super.data = value;
                                formattedValue = data[(listData as 
DataGridListData).dataField];
                                this.selected = formattedValue;
                        }

                        override protected function 
clickHandler(event:MouseEvent):void
                        {
                                super.clickHandler(event);
                                formattedValue = 
data[DataGridListData(listData).dataField] =
selected;
                        }
                ]]>
        </mx:Script>
</mx:CheckBox>

Please help how to resolve my issue.

-- 
You received this message because you are subscribed to the Google Groups "Flex 
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/flex_india?hl=en.

Reply via email to