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

ComboBox Rebind/Filter on Text Deleted

2 Answers 74 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
webHDSB
Top achievements
Rank 1
webHDSB asked on 12 Dec 2014, 03:11 PM
When using the minLength configuration setting, a ComboBox initially respects the minLength and does not bind or filter data (dataBound & filtering event handlers not called) until the minLength is reached by the combo's text.

However, when deleting text from the input, the minLength works until all the text is deleted. At that point (there is no longer any text in the input), the event handlers for dataBound & filtering are called even though the length is 0 (ie. not at minLength).

Is this a bug or is there a way for the minLength to continue to work when all text has been removed? This behaviour can be seen using an example from the Dojo: http://dojo.telerik.com/aPEba

This becomes more problematic when the data that is bound is much larger, hence the use of the minLength configuration for search.

2 Answers, 1 is accepted

Sort by
0
Accepted
Georgi Krustev
Telerik team
answered on 16 Dec 2014, 09:10 AM
Hello,

The described behavior is intended, as we've got many bug reports that widget will not clear filter when "minLength" is defined and thus the widget behaves unexpected for the end user. You can overcome this behavior preventing the filtering of the widget. Wire the filtering event and call "e.preventDefault()" when filter value is empty. Check the updated demo.

Regards,
Georgi Krustev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
webHDSB
Top achievements
Rank 1
answered on 17 Dec 2014, 01:23 PM
Perfect, thanks Georgi.
Tags
ComboBox
Asked by
webHDSB
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
webHDSB
Top achievements
Rank 1
Share this question
or