This is a migrated thread and some comments may be shown as answers.

grid collapse/exand all groups

4 Answers 1451 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Dr.YSG
Top achievements
Rank 2
Dr.YSG asked on 18 Apr 2012, 03:09 PM
I am looking for a method that would be called to toggle expand/collapse all groups (the grid has the attribute groupable).

You have this in the Telerik Silverlight Grid.

4 Answers, 1 is accepted

Sort by
0
Bob
Top achievements
Rank 1
answered on 19 Apr 2012, 07:29 PM
You should be able to do:

$(".k-collapse").click()

and

$(".k-expand").click()
0
Accepted
Alexander Valchev
Telerik team
answered on 23 Apr 2012, 03:04 PM
Hello Steven,

This functionality is currently not supported out of the box, but you could achieve it by triggering the click event of the expand/collapse arrows as Bob mentioned.

For convenience I made a small example to illustrate this approach in action.

Kind regards,
Alexander Valchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Dr.YSG
Top achievements
Rank 2
answered on 23 Apr 2012, 08:47 PM
Alexander,

Thank you very much. BTW. I hope you saw that I closed out the support ticket about the dynamic chart aggregates that you were working on. In the rating, I included a letter of commendation to your supervisor, on what I consider completely superlative work.  I hope he sees it, but if not, I can regenerate it for you.


0
Dfresh
Top achievements
Rank 1
Iron
answered on 25 Jun 2023, 05:18 AM

Note in the latest version, I had to use this.

    $(document).ready(function () {
        $("#expandGroups").click(function (e) {
            //e.preventDefault();
            $("#workingGroupGrid").find(".k-icon.k-i-expand").trigger("click");
        });

        $("#collapseGroups").click(function (e) {
            //e.preventDefault();
            $("#workingGroupGrid").find(".k-icon.k-i-collapse").trigger("click");
        });
    });
Tags
Grid
Asked by
Dr.YSG
Top achievements
Rank 2
Answers by
Bob
Top achievements
Rank 1
Alexander Valchev
Telerik team
Dr.YSG
Top achievements
Rank 2
Dfresh
Top achievements
Rank 1
Iron
Share this question
or