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

[Solved] Export CVS - client side Group By

3 Answers 73 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Jigar
Top achievements
Rank 1
Jigar asked on 11 Nov 2010, 08:23 AM
Hi,

I want to export my data as per the group in grid. I am able to export data as per sorting, filter and page wise (demo) but I don't get a clue on how can I replace that href with groupBy data.

Can any one help please?

Thanks,

Jigar.

3 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 11 Nov 2010, 08:25 AM
Hello Jigar,

As far as I know the CSV format does not support groups.

All the best,
Atanas Korchev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Jigar
Top achievements
Rank 1
answered on 11 Nov 2010, 08:28 AM
Hi Atanas,

Thanks for your response. Right you have a valid point.

Thanks,

Jigar.
0
judowalker
Top achievements
Rank 1
answered on 03 Apr 2011, 06:59 AM
Hi Atanas,

I'm using the article you wrote (http://www.telerik.com/support/kb/aspnet-mvc/grid/export-to-excel.aspx) to export my grid data to excel. I would like to export the groupings as well.

I noticed the ToGridModel method (example below) takes a groupBy parameter but your example passes in string.empty. Is there a way to pass it the groupBy query string and have it return an IGrouping. Or is there a way to cast the GridModel.Data IEnumerable into an IGrouping?

GridModel model = Model().ToGridModel(page, 10, orderBy, string.empty, filter);

This will allow me to loop through each group in the grouping in order to create the rows in the spreadsheet.

Thanks,
Tudor
Tags
Grid
Asked by
Jigar
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Jigar
Top achievements
Rank 1
judowalker
Top achievements
Rank 1
Share this question
or