I want to populate kendo grid based on button click.
Code
<input id="Submit" type="button" value="Display value" onclick="PopulatePriceGrid()" />
function PopulatePriceGrid() {
var value1 = $("#value1").val();
var value2= $("#value2").val();
}
In the above function PopulatePriceGrid() i need to get the results from database based on two values values1 and values 2. the results should be populated with kendogrid.
Can anyone help me in this scenario
You can do it by calling the read method of the grid's data source:
function PopulatePriceGrid() {
var value1 = $("#value1").val();
var value2= $("#value2").val();
$("#grid").data("kendoGrid").dataSource.read( { value1: value1, value2: value2 });
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.