The DataGrid, List, and Tree controls include an editable property that you set to true to let users edit the contents of the control. By default, the value of the editable property is false, which means that you cannot edit the cells. For a DataGrid control, setting the editable property to true enables editing for all columns of the grid. You can disable editing for any column by setting the DatagridColumn.editable property to false.
Your list-based controls can use the default item editor (TextInput control), a custom item editor, or a custom item renderer as an editor. The rendererIsEditor property of the list-based controls determines whether you can use an item renderer as an item editor, as the following table shows:
|
rendererIsEditor property |
itemRenderer property |
itemEditor property |
|---|---|---|
|
false (default) |
Specifies the item renderer. |
Specifies the item editor. Selecting the cell opens the item editor as defined by the itemEditor property. If the itemEditor property is undefined, use the default item editor (TextInput control). |
|
true |
Specifies the item renderer to display the cell contents. You can use the item renderer as an item editor. |
Ignored. |
As this table shows, the state of the rendererIsEditor property defines whether to use a custom item renderer as the item editor, or a custom item editor. If you set the rendererIsEditor property to true, Flex uses the item renderer as an item editor, and ignores the itemEditor property.
For an example, see Example: Using an item renderer as an item editor.