Kendo UI DropDownList DataBound Event
Demonstrate Kendo UI DropDownList DataBound Event
by jddevight
HTML
<link rel="stylesheet" href="http://cdn.kendostatic.com/2012.2.710/styles/kendo.common.min.css">
<link rel="stylesheet" href="http://cdn.kendostatic.com/2012.2.710/styles/kendo.default.min.css">
<script src="http://cdn.kendostatic.com/2012.2.710/js/kendo.all.min.js"></script>
<input id="customers"></input>
JavaScript
var _customers = $("#customers").kendoDropDownList({
index: 0,
placeholder: "Select Customer",
dataTextField: "CompanyName",
dataValueField: "CustomerID",
filter: "contains",
dataSource: {
type: "odata",
serverFiltering: true,
serverPaging: true,
pageSize: 20,
transport: {
read: "http://services.odata.org/Northwind/Northwind.svc/Customers"
}
}
}).data("kendoDropDownList");
_customers.bind("dataBound", function() {
_customers.select(5);
});