Editor is created after itemEditBegin. The recommended practice is to subclass the itemEditor.
Maybe cheat by using focusIn event. On 6/24/10 12:36 PM, "ilikeflex" <[email protected]> wrote: Hi I have datagrid and i am using the default itemeditor. I want to limit the charatcres the user can enter. I have implemented itemEditBegin method on datagrid. private function onitemEditBegin(event:DataGridEvent):void { var datGrid:CheckBoxDataGrid=(event.currentTarget as CheckBoxDataGrid); var customDataGridColumn:CustomDataGridColumn = datGrid.columns[event.columnIndex] as CustomDataGridColumn; var field:String=datGrid.columns[event.columnIndex].dataField; if(field == "prlName") { var editor:TextInput = datGrid.itemEditorInstance as TextInput; editor.maxChars = 5; } } I always get editor as null... so i am not able to set maxChars on TextInput. How to do this.. Any pointers. Thanks ilikeflex -- Alex Harui Flex SDK Team Adobe System, Inc. http://blogs.adobe.com/aharui

