1
votes

This is the Kendo UI demo showing hierarchical data: http://demos.telerik.com/kendo-ui/grid/hierarchy

It seems to work very well, but the first row is expanded automatically. I tried hacking around with it in their dojo, but couldn't find a way to disable that behavior.

How do I prevent rows from being automatically expanded in Kendo UI Grid?

1

1 Answers

2
votes

It's because there is used expandRow method in dataBound event to expand first row. Remove it.

var element = $("#grid").kendoGrid({
    ....
    dataBound: function() {
        this.expandRow(this.tbody.find("tr.k-master-row").first());
    },
    ....
});