This question is locked. New answers and comments are not allowed.
Hello,
I'm trying to use populate the autocomplete box using a remote data source. This remote data source requires a query to be included in the URL. So I'd like to:
- Listen for a change in the value of the autocompletebox
- If there is a change then get the current value of the autocompletebox
- Get the current value and use that in my query to my remote data source, query data source
- Repeat (i.e. continue to listen)
The problem I'm running into is that the change events on the autocomplete box don't fire until I click off of the autocompletebox. Is there a way to listen for a change even when the autocompletebox is active?
Currently using:
var autoComplete = new Telerik.UI.RadAutoCompleteBox(document.getElementById("autocompleteBox"), { placeholder: 'Input', dataSource: customersSource, dataTextField: "name", //onchange: function (e) { new Windows.UI.Popups.MessageDialog("Message", "Title").showAsync().done(); }});var autocompletes = document.getElementById("autocompleteBox").winControl;autocompletes.addEventListener("change", this.searchYahoo);My eventListener is:
searchYahoo: function (eventInfo) { new Windows.UI.Popups.MessageDialog("Message", "Title").showAsync().done();}I get the same behavior when using onchange: during initialization.
Thanks,
Nikhil