content jQuery

The jQuery object which represents the grid content element, which holds the scrollable content. Available only in a grid with locked columns.

Example - hightligh the cells within the content of the grid

<div id="grid"></div>
<br />
<button id="btn" class='k-button'>Highlight content's cells</button>
<script>
  $("#grid").kendoGrid({
    columns: [
      { locked: true, field: "id", width:200 },
      { field: "name", width:800 }
    ],
    dataSource: [ { id: 1, name: "Jane Doe" }, { id: 2, name: "John Doe" } ]
  });

  $("#btn").click(function(e){
    var gridContent = $("#grid").getKendoGrid().content;
    var cells = gridContent.find("td");
    cells.css("color", "green");
  });
</script>
In this article
Not finding the help you need? Improve this article