I know, the title sounds insane, but in an attempt to refactor some code, I am having trouble figuring out how to programmatically fire an event without using the following:
- trigger
- change
- click
The code below loads on a hook, and all I need to do is click inside the ID element below, but 'click();' or .on('click') aren't an option.
$("#id").data("kendoDropDownList").text(data[i].Text);
$("#id").data("kendoDropDownList").trigger('change'); // code that needs to be refactored
CodePudding user response:
I think you can use focus function.
$("#id").data("kendoDropDownList").focus()