Here below is my code. How do you get the primay key value. I can see the correct field in the debugger under
this._data._key.ID=3 this is correct, I just need some help getting that value. I have searched the forums but couldn't find a working example
Thanks.
this._data._key.ID=3 this is correct, I just need some help getting that value. I have searched the forums but couldn't find a working example
Thanks.
function BindData (myArray){
$(document).ready(function() {
$("#grid").kendoGrid({
dataSource: {
data: myArray,
pageSize: 10
},
change: onChange,
selectable: "multiple",
navigatable: true,
groupable: true,
sortable: true,
pageable: {
refresh: true,
pageSizes: true
},
columns: [ {
field: "firstname",
width: 90,
title: "firstname:"
},
{
field: "lastname",
width: 90,
title: "lastname:"
}
]
});
});
}
function onChange(arg) {
var selected = $.map(this.select(), function(item) {
return $(item).text();
});
;
sources.people.select(1)
kendoConsole.log("Selected: " + selected.length + " item(s), [" + selected.join(", ") + "]");
}