For making default value selected, You can do like this
$("#element-id").data("kendoDropDownList").value(your-value);
by using above, you can set directly value in kendo dropdown.
or if you want to select some option from the kendo dropdown by comparing some values then you can do it like thisβ¦.
suppose, you initialize dropdown with datasource like this.
$("#element-id").kendoDropDownList({
dataTextField: "companyname",
dataValueField: "companyid",
dataSource: dataComp,
optionLabel: "--Select Company--"
});
so you can do like this
$("#element-id").data("kendoDropDownList").select(function (dataItem) {
return dataItem.companyname === "Rahulya Info Tech";
});
You May Also Like:-