Clear the content in the grid.
Parameters
Name | Type | Description |
---|---|---|
showNotFoundText | {boolean} | Indicates if the "Not Found" text is going to show after the clearing of the grid. |
Examples
sample
<button id="btnClear">Clear</button>
<br/><br/>
<table id="grid"></table>
<script>
var grid = $('#grid').grid({
dataSource: '/0_6/Grid/GetPlayers',
columns: [ { field: 'ID' }, { field: 'Name' }, { field: 'PlaceOfBirth' } ]
});
$('#btnClear').on('click', function () {
grid.clear();
});
</script>