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

Autocomplete - IE 9 - select event - A bug and a Fix

1 Answer 29 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
Sakthivel
Top achievements
Rank 1
Sakthivel asked on 14 Jun 2012, 12:43 PM
When we press the enter key without selecting any item from the opened list area of an Autocomplete kendo plug-in, we may get an error 
"Line: 217. Error: Unable to get value of the property 'index': object is null or undefined"
in IE9. This is because the "item" object of the passed-in parameter "e" is null. The following fixed me this issue.

if (e.item == null) return;
                var dataItem = this.dataItem(e.item.index());
I hope that a developer like me, makes use of this.

1 Answer, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 18 Jun 2012, 08:37 AM
Hello Sakthivel,

 
Thank you for drawing attention to this issue. We decided to not raise select event, when end-user enters custom value and press ENTER. Thus the error will not be thrown. I have updated your Telerik points for the report.

Regards,
Georgi Krustev
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
Sakthivel
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Share this question
or