cellDataBound

Event fires after insert of a cell in the grid during the loading of the data

Parameters

NameTypeDescription
e {object} event data
$wrapper {object} the cell wrapper presented as jquery object
id {string} the id of the record
column {object} the column configuration data
record {object} the data of the row record

Examples

sample

    
 <table id="grid"></table>
 <script>
     var grid = $('#grid').grid({
         dataSource: '/0_6/Grid/GetPlayers',
         columns: [ { field: 'ID' }, { field: 'Name' }, { field: 'PlaceOfBirth' }, { field: 'Bulgarian', title: 'Is Bulgarian?' } ]
     });
     grid.on('cellDataBound', function (e, $wrapper, id, column, record) {
         if ('Bulgarian' === column.field) {
             $wrapper.text(record.PlaceOfBirth.indexOf('Bulgaria') > -1 ? 'Yes' : 'No');
         }
     });
 </script>