         inEndEdit = true;
         
         var itemPosition:Object = editedItemPosition;
+        var editedItem:Object = itemEditorInstance.data;
         if (!saveItemEditorSession())
         {
             // The save was cancelled so check if the editor can be cancelled.

        
        dataGridEvent.columnIndex = editedItemPosition.columnIndex;
        dataGridEvent.column = itemEditorInstance.column;
        dataGridEvent.rowIndex = editedItemPosition.rowIndex;
        dataGrid.dispatchEvent(dataGridEvent);
    }
    

        // GRID_ITEM_EDITOR_SESSION_SAVE events are NOT cancelable
        dataGridEvent.columnIndex = itemPosition.columnIndex;
        dataGridEvent.column = dataGrid.columns.getItemAt(itemPosition.columnIndex) as GridColumn;
        dataGridEvent.rowIndex = dataGrid.dataProvider ? dataGrid.dataProvider.getItemIndex(editedItem) : -1;
        dataGrid.dispatchEvent(dataGridEvent);

        inEndEdit = false;
