This is a migrated thread and some comments may be shown as answers.

Completely reset an AutComplete from a Web Service

1 Answer 61 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
Stan
Top achievements
Rank 1
Stan asked on 03 Jan 2013, 01:05 AM
I am having a problem here getting an AutoComplete to completely refresh.  It is actually tied to the text as well as another dropdown, so when the dropdown changes, I want to 'forget' it ever looked anything up.  Once I type into my AC, it works perfectly, but trying to reset it is proving to be a problem.  I am doing the following:

$('#clear').on('click', function(e) {
    e.preventDefault();
    acManConfId.value(""); // .data("kendoAutoComplete"); object
    kendoManufacturerConfirmationIdDataSource.filter({}); //autocomplete datasource
});

But I am still not getting new reads over ajax in my firebug console, it is just reading from the old data.  All I want is to have the whole thing completely reset.  Thank you.

1 Answer, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 04 Jan 2013, 04:26 PM
Hello Stan,

You can use the autocomplete dataSource read method to reload the data from the service:

acManConfId.dataSource.read();
Kind regards,
Daniel
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
AutoComplete
Asked by
Stan
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Share this question
or