SMART datagrid v.1 > Classes > CellIndex

Back  Forward

DataLudi.CellIndex.columnIs  method

如果参数columnNamecolumncolumn的名称相同,就会返回true。 

function columnIs (columnName: String|GridColumn, ignoreCase: Boolean): Boolean;
Returns
Boolean
Parameters
columnName - String|GridColumn. required.
将会相比的列名称或列对象。
ignoreCase - Boolean. 默认值为false.
当相比名称时,如果该值为true,就不会区分大小写。
Code -1
    grid.onGetEditValue = function (grid, index, editResult) {
        if (index.columnIs('orderid', true)) {
            editResult.value += '_x';
        }
    }
See Also
column
rowIndex
GridColumn
Examples
聚焦单元格