SmartClient : Smartclient v9.0p_2014-01-15 - Power Edition
Browser : IE 10
I have editable ListGrid with editEvent: "doubleClick".
For one of the columns, I am have to display formatted value.
So I am overriding formatCellValue() to show formatted value in view mode
and formatEditorValue() to show formatted value in edit. i.e. when user double click the cell.
Looks like formatEditorValue() is not called when user tabs out of that cell and moves to next cell.
Is there a way to format the editor value when user tabs out of the cell ? Please suggest.
Below is my sample code
Browser : IE 10
I have editable ListGrid with editEvent: "doubleClick".
For one of the columns, I am have to display formatted value.
So I am overriding formatCellValue() to show formatted value in view mode
and formatEditorValue() to show formatted value in edit. i.e. when user double click the cell.
Looks like formatEditorValue() is not called when user tabs out of that cell and moves to next cell.
Is there a way to format the editor value when user tabs out of the cell ? Please suggest.
Below is my sample code
Code:
isc.ListGrid.create({ ID: "myListGrid", autoFetchData: false, dataSource: myDS, showRollOver: true, showHeaderContextMenu:false, leaveScrollbarGap: false, showFilterEditor:false, baseStyle: "cell", autoSaveEdits: false, canEdit: true, fields:[ { name:"col1", canSort: true,canEdit: true, formatCellValue: function (value, record, rowNum, colNum,grid) { if(value!=null && !(value.isNaN)) { return isc.Format.toUSString(value,2); } else return value; }, formatEditorValue: function (value, record, rowNum, colNum,grid) { if(value!=null && !(value.isNaN)) { return isc.Format.toUSString(value,2); } else return value; }, parseEditorValue : function (value, record, rowNum, colNum,grid) { if(value!=null ) { var rawValue = value.replace(new RegExp(',', 'g'), ''); return rawValue; } }, }, {name:"col2", canSort: true,canEdit: true}, {name:"col3", canSort: true,canEdit: true} ] })
Comment