Hello,
I checked your code there is one immediate issue. The data source read method is asynchronous. This means that the response will not be received immediately after calling read(). You should use the change event of the datasource instead:
$(document).ready(function () {
var dataSource = new kendo.data.DataSource({
transport: { read: "/api/Institution/1", dataType: "json" },
schema: { model: { id: "Id", fields: { Id: { type: "string" }, Name: { type: "string" } } } } ,
change: function() {
var viewModel = kendo.observable({
inst: this.view()[0]
});
kendo.bind($("div#InstitutionHeader"), viewModel.inst);
}
});
Regards,
Atanas Korchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework -
download Kendo UI now!