It appears to not be possible to programmatically select a specific value in the Kendo DropDownList element. I checked the API, but wasn't able to find something to trigger this.
There is a selectionChange event, but this is triggered by manually selecting a value from the dropdown. I'm interested in programmatically selecting an event; is there any way to do this?
Kendo does not take the new value unless we trigger the change event for the drop-down list. Once we set the value we have to trigger the change event
var menulist = $("#menulist").data("kendoDropDownList");
menulist.value("Top");
menulist.trigger("change");
Add the following to the dropdown html tag: (selectionChange)="selectionChange($event)"
And add the following to your typescript code:
protected selectionChange(value): void {
console.log("The current value is: " + value)
}
To change the selected item from the code behind, use this: http://www.telerik.com/kendo-angular-ui/components/dropdowns/api/DropDownListComponent/#toc-value
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With