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

ComboBox bug with Q1'12 beta

4 Answers 95 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Yvan
Top achievements
Rank 1
Yvan asked on 07 Mar 2012, 10:22 PM
Hi,

ComboBox seems to not work well in Q1'12 beta version.

Consider the following trivial code:

$("#aCombobox").kendoComboBox([
 {text: "Item1", value: "1"},
 {text: "Item2", value: "2"}
]);

The result in combobox is always : [object Object] instead ItemN.

Best regards
Yvan

4 Answers, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 08 Mar 2012, 09:20 AM
Hello Yvan,

 
This is a breaking change which is described in the Changes and Backward Compatibility section.

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!
0
Yvan
Top achievements
Rank 1
answered on 08 Mar 2012, 09:35 PM
Hello Georgi,

Thanks for your answer but unfortunately the link seems to be broken.

Never mind, I found this page:
http://www.kendoui.com/documentation/changes-and-backward-compatibility.aspx

But except the following sentence I haven't found information about combo box:
Other: dataValueField and dataTextField of DropDownList, ComboBox and AutoComplete, are set to empty string by default.

What is the change you are talking about?

Best regards
Yvan
0
Accepted
Kamen Bundev
Telerik team
answered on 09 Mar 2012, 09:02 AM
Hi Yvan,

Sorry about the link, seems you've found the right one. Yes, this is the breaking change - in order to get your ComboBox working, you will need to list the fields you want to bind it to, like this:
$("#aCombobox").kendoComboBox({
    dataTextField: "text",
    dataValueField: "value",
    dataSource: [
        {text: "Item1", value: "1"},
        {text: "Item2", value: "2"}
    ]
});


That said, the change was needed for the MVVM implementation. I went ahead and changed the documentation to be more clear about what you need to change.

Kind regards,
Kamen Bundev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Yvan
Top achievements
Rank 1
answered on 11 Mar 2012, 10:05 PM
Hi Kamen,

Thanks for your answers.

Best regards,
Yvan
Tags
ComboBox
Asked by
Yvan
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Yvan
Top achievements
Rank 1
Kamen Bundev
Telerik team
Share this question
or