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

Excel export formats

3 Answers 173 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Rezo
Top achievements
Rank 1
Rezo asked on 29 Aug 2016, 02:00 PM

Hello,

 

When I export result in excel(xls) all cell formats are "custom", how can I keep date format on cells where dates are written?

3 Answers, 1 is accepted

Sort by
0
Stef
Telerik team
answered on 29 Aug 2016, 03:33 PM
Hi Rezo,

Format strings are always saved as custom in order to avoid the incorrect interpretation by machines due to their custom culture settings.

For more details, please check Design Considerations for Excel Rendering.

Regards,
Stef
Telerik by Progress
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 Feedback Portal and vote to affect the priority of the items
0
Rezo
Top achievements
Rank 1
answered on 29 Aug 2016, 04:11 PM

Hi and thanks Steff,

 

Is there any workaround? I have to import output excel in some third party tool, which is crashing because of custom formats on dates. 

 

 

0
Stef
Telerik team
answered on 30 Aug 2016, 11:54 AM
Hello Rezo,

It must be an issue with the used Datetime format string. Please test using the standard format strings, where the field must be of DataTime type. Or format the field in the expression, where the result can be string instead of a DateTime object e.g.:
TextBox.Value = "=Fields.Date.ToString('dd/MM/yy')";


Regards,
Stef
Telerik by Progress
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 Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
Rezo
Top achievements
Rank 1
Answers by
Stef
Telerik team
Rezo
Top achievements
Rank 1
Share this question
or