Suppose you are using jQuery
var grid;
$(function () {
// init options, load data
...
var columns = [];
columns[0] = {
id: id ,
name: # ,
field: id , // suppose you have an id column in your data model
formatter: function (r, c, id, def, datactx) {
return <a href="#" onclick="RemoveClick( + id + , + r + )">X</a> ; }
}
// init other columns
...
grid = new Slick.Grid($( #gridDiv ), data, columns, options);
}
function RemoveClick(databaseId, gridRow) {
// remove from serverside using databaseId
...
// if removed from serverside, remove from grid using
grid.removeRow(gridRow);
}