Hi,

In addition to setting the isCellEditor=true flag you
also need to set  editorProperty=selected for your
code to function correctly with a
checkBoxCellRenderer. In your code, since the editable
is set to true, clicking on the Datagrid cell tries to
bring the default editor which is the textinput since
the editorproperty is not set. 

There is a known issue about the checkbox selections
getting messed up on scrolling after selecting the
checkboxes, which is currently under investigation.

Please have a look at the code below, This works
without the runtime error:

//------------------------------------
<?xml version="1.0" encoding="iso-8859-1"?>
<mx:Application
xmlns:mx="http://www.macromedia.com/2005/mxml";
width="600" height="600" >
<mx:Script>
<![CDATA[
import mx.controls.gridclasses.*;
[Bindable]
public var
myarr:Array=[{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"false"},{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"true"},{description:"one",product:"false"},{description:"one",product:"true"},{description:"one",product:"true"}]
]]>
</mx:Script>
    <mx:DataGrid dataProvider="{myarr}"
id="myDataGrid2" width="100%" height="250" 
variableRowHeight="true" wordWrap="true"
editable="false" dropEnabled="true">
          <mx:columns>
           <mx:Array>
            <mx:DataGridColumn headerText="Column4"
columnName="description"
cellRenderer="mx.controls.CheckBox" editable="true"
isCellEditor="true" editorProperty="selected"/>
            <mx:DataGridColumn headerText="Column5"
columnName="product"  />
            <mx:DataGridColumn headerText="Price"
visible="true" columnName="price" />
           </mx:Array>
  </mx:columns>
  </mx:DataGrid>
</mx:Application>
//--------------------------------------------


Hope this helps!

Thanks,
Harish
Flex-QA
Adobe India.




--- thunderstumpgesatwork <[EMAIL PROTECTED]>
wrote:


---------------------------------
Hi all, I have set up a "selected" column in a
datagrid and am using a
checkbox as the cell editor. Clicking around on
different rows of the
datagrid produced this error:

ReferenceError: Error #1069: Property text not found
on
mx.controls.CheckBox and there is no default value
at
mx.controls::DataGrid/mx.controls:DataGrid::cellEditorCellEndEditHandler()[C:\dev\beta1\sdk\frameworks\mx\controls\DataGrid.as:4311]
at flash.events::EventDispatcher/dispatchEvent()
at
mx.controls::DataGrid/endEdit()[C:\dev\beta1\sdk\frameworks\mx\controls\DataGrid.as:3089]
at
mx.controls::DataGrid/mouseDownHandler()[C:\dev\beta1\sdk\frameworks\mx\controls\DataGrid.as:3618]

The column definition is as such:
<mx:DataGridColumn width="15" id="MergeItemSel"
headerText=" "
cellRenderer="mx.controls.CheckBox" editable="true"
isCellEditor="true" columnName="selected" />

Any ideas? Is this a known bug?

thanks,
Thunder





--
Flexcoders Mailing List
FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com

      

      SPONSORED LINKS  
                                                Web
site design development                               
    Computer software development                     
              Software design and development         
                                                     
Macromedia flex                                   
Software development best practice                    
                  
    
---------------------------------
  YAHOO! GROUPS LINKS

  
    Visit your group "flexcoders" on the web.
   
    To unsubscribe from this group, send an email to:
 [EMAIL PROTECTED]
   
    Your use of Yahoo! Groups is subject to the Yahoo!
Terms of Service.

  
---------------------------------




__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to