Chester John
Chester John

Reputation: 85

Auto-Expand Kendo Grid on Load

I'm using a Kendo Grid on my ASP.Net MVC Web Application, I want to auto expand the trees on Load. I've searched the internet but I couldn't find any solution.

This is what my grid looked like on load:

Auto-collapsed

I want it to auto-expand expand on load like this:

enter image description here

Is there any way to do it? Thanks.

Upvotes: 0

Views: 660

Answers (1)

pool pro
pool pro

Reputation: 2114

The expandRow method of the Grid accepts a single row or a collection of rows as a parameter, so you could pass all master rows.

dataBound: function() {
    this.expandRow(this.tbody.find("tr.k-master-row"));
}

This can be found in the documentation here Link

Upvotes: 1

Related Questions