transport: {
read: "http://localhost/WebAPITest/api/Transactions",
datatype: "json",
headers: { Authorization: "user/password" }
},
this.ComboBox = this.kendoComboBox();
this.ComboBox.setName("COMBOID");
this.ComboBox.setWidth(550);
this.ComboBox.setHeight(33);
this.ComboBox.setIndex(0);
this.ComboBox.setdataTextField("Name");
this.ComboBox.setdataValueField("ID");
this.ComboBox.setFilter("Contains");
this.ComboBox.setDataType("odata");
this.ComboBox.setserverFiltering("true");
this.ComboBox.setServerPaging("true");
this.ComboBox.setPageSize("20");
would generate the following results will :
$("#comboBox").kendoComboBox({
index: 0,
dataTextField: "Name",
dataValueField: "Id",
filter: "contains",
dataSource: {
type: "odata",
serverFiltering: true,
serverPaging: true,
pageSize: 20,
transport: {
read: "http://odata.netflix.com/Catalog/Titles" } } });
thanks.
<script id="template" type="text/x-kendo-template"> <div id="content"> <div id="RepairNum"> Repair:#= RepairNum # Customer:#= CustomerName # </div> </div> </script><script> function Repair(repairNum,customerName) { this.RepairNum = repairNum; this.CustomerName = customerName; } var repairs = new Array(); repairs.push(new Repair("111111","Test1")); repairs.push(new Repair("222222","Test2")); repairs.push(new Repair("333333","Test3")); $(document).ready(function() { var template = kendo.template($("#template").html()); $("#main").html(kendo.render(template, repairs)); $("#addButton").click(function(){ //Attempt to get the customer name var repairNum = $("#repairnum").val(); $.get('/app/json.mx', {RepairNum : repairNum}, function(data) { repairs.push(new Repair(repairNum,data)); $("#main").html(kendo.render(template, repairs)); }); $("#repairnum").val(""); $("#repairnum").focus(); }); });</script>$("#grid").kendoGrid({ columns: [ "Id", "HostName", "BaseUri", { field: null,command: "destroy"} ], editable: true, remove: function(row) {alert("removed");} });$("#grid").kendoGrid({
remove: function(e) {
// handle event
});
have not been working for me$("#grid").data("kendoGrid").dataSource.data(message).read();