4 Answers, 1 is accepted
You can use the jQuery focus() method to check when the combobox is focused, and attach it to the input that is actually holding the Kendo UI Combobox.
$(
"#YourComboBox"
).data(
"kendoComboBox"
).input.focus(
function
(){
console.log(
"focus"
);
});
Regards,
Kiril Nikolov
Telerik
Hi Kiril,
It is not working in my case. I want to call key press event in kendo combobox. Please consider my example:
ComboBox:
@(Html.Kendo().ComboBox()
.Name("cmbChopOwnerAssistance")
.DataTextField("Name")
.DataValueField("Id")
.HtmlAttributes(new { style = "width:380px;" })
.Filter("contains")
)
In Javascript:
$.ajax({
url: '@Url.Action("LoadUsers", "List")',
type: 'GET',
cache: false,
data: { UserId: AssistantId },
success: function (data) {
$("#cmbChopOwnerAssistance").kendoComboBox({
dataTextField: "Name",
dataValueField: "Id",
dataSource: data
});
}
});
Thank you for your help.
Dear Kiril,
It is resolved by using the following example:
http://docs.telerik.com/kendo-ui/api/javascript/ui/combobox
Thank you so much for your time.
I am happy to hear that the problem has been resolved. In case you have any further questions do not hesitate to contact us.
Regards,
Kiril Nikolov
Telerik