Hello,
I've started playing with kendo and I got a problem with getting the data on the eventchanged... my code is
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<input id="comboBox" />
<script>
$(document).ready(function () {
$("#comboBox").kendoComboBox({
dataTextField: "text",
dataValueField: "value",
dataSource: [
{ text: "Item1", value: "1" },
{ text: "Item2", value: "2" }
],
change: function (e) {
var combobox = $("#comboBox").data("kendoComboBox");
var selectedIndex = combobox.select();
alert(combobox.select().text);
}
});
});
</script>
</asp:Content>
How do I get the object I've selected? for now it's as imple text/value what if it's an object of type
text, value, additionalinfo?
Thanks
I've started playing with kendo and I got a problem with getting the data on the eventchanged... my code is
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<input id="comboBox" />
<script>
$(document).ready(function () {
$("#comboBox").kendoComboBox({
dataTextField: "text",
dataValueField: "value",
dataSource: [
{ text: "Item1", value: "1" },
{ text: "Item2", value: "2" }
],
change: function (e) {
var combobox = $("#comboBox").data("kendoComboBox");
var selectedIndex = combobox.select();
alert(combobox.select().text);
}
});
});
</script>
</asp:Content>
How do I get the object I've selected? for now it's as imple text/value what if it's an object of type
text, value, additionalinfo?
Thanks