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

Excel Export with group by date only

2 Answers 166 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Kyle Smith
Top achievements
Rank 1
Kyle Smith asked on 04 Nov 2019, 06:42 PM

I followed the group by date only example in the knowledge base. Works great.

https://docs.telerik.com/kendo-ui/knowledge-base/grid-group-by-date-only

 

The only issue I have is that when I export to excel, i get only the date portion of the value even though the grid displays the date and time via the template. How can I get around this so Excel export also uses the template value?

2 Answers, 1 is accepted

Sort by
0
Kyle Smith
Top achievements
Rank 1
answered on 04 Nov 2019, 07:56 PM

FYI,

I got around this by adding a new column to have the "No Time" value and set it to be hidden. That way the grouping works based on that column and the actual column value shows with the time value and exports to excel with the time value.

0
Viktor Tachev
Telerik team
answered on 06 Nov 2019, 01:39 PM

Hi Kyle,

Thank you for sharing the approach you went for with the community.

The implementation you are using is suitable for this scenario. Out of the box templates are not exported to Excel - only the data. The reason for this is that a template can include arbitrary HTML that cannot be converted to valid values in Excel. For more information on the excel export feature check out the article below:

https://docs.telerik.com/kendo-ui/controls/data-management/grid/export/excel-export

 

Regards,
Viktor Tachev
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Grid
Asked by
Kyle Smith
Top achievements
Rank 1
Answers by
Kyle Smith
Top achievements
Rank 1
Viktor Tachev
Telerik team
Share this question
or