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

Exporting Report to Excel - Loss of Format Integrity

1 Answer 62 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Joe
Top achievements
Rank 1
Joe asked on 15 Jun 2015, 01:19 PM

I have one textbox on my report with the value of .55 and the format is set as {0:N2}.  Now when I export to excel the format for said cell becomes [$-1010409]#,##0.00;-#,##0.00 under the Custom Category .  I would like some help in understanding why the format is not behaving as expected for the excel.  I researched and saw this thread:

 http://www.telerik.com/forums/report-lose-formatting-after-export-in-excel

The answer that {0:N2} would be the solution isn't working for me for some reason.  Just in case it's needed I am using the ReportProcessor.RenderReport method for my generation.

Thank you

1 Answer, 1 is accepted

Sort by
0
Stef
Telerik team
answered on 16 Jun 2015, 02:02 PM
Hi Joe,

Reports are rendered in Excel based on the Design Considerations for Excel Rendering.

Thus a Textbox item's content is formatted based on the TextBox.Format property, if set.
Then the Excel cell format will be with respect to the TextBox.Format property and the culture used on rendering the report. Note that report's formats are applied as Excel custom formats to avoid issues due to interpreting one and the same format string differently on machines with custom culture settings.


I hope the provided information is helpful.

Regards,
Stef
Telerik
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
Joe
Top achievements
Rank 1
Answers by
Stef
Telerik team
Share this question
or