Steema Issues Database

Note: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;
otherwise you can use StackOverflow.
Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy.



Bug 1257 - Exported data to xls doesn't open in Excel 2013
Summary: Exported data to xls doesn't open in Excel 2013
Status: RESOLVED FIXED
Alias: None
Product: VCL TeeChart
Classification: Unclassified
Component: Export (show other bugs)
Version: 150120
Hardware: PC Windows
: High critical
Target Milestone: v2017.20
Assignee: marc meumann
URL: http://www.teechart.net/support/viewt...
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-22 12:06 EDT by yeray alonso
Modified: 2018-12-12 06:35 EST (History)
8 users (show)

See Also:
Chart Series: ---
Delphi / C++ Builder RAD IDE Version:


Attachments
warning (53.64 KB, image/jpeg)
2015-07-22 12:08 EDT, yeray alonso
Details
error (119.31 KB, image/jpeg)
2015-07-22 12:08 EDT, yeray alonso
Details
Export in ods (5.00 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-08-04 10:25 EDT, boris.seve
Details
Export in text format (7.04 KB, text/plain)
2015-08-04 10:27 EDT, boris.seve
Details
Broken file, exported using v2016.19 (59.26 KB, application/vnd.ms-excel)
2016-12-07 10:55 EST, boris.seve
Details

Note You need to log in before you can comment on or make changes to this bug.
Description yeray alonso 2015-07-22 12:06:34 EDT
This can be reproduced with Export_Excel example in the features demo.
You can export to an .xls without problems.
The generated document opens fine in Excel 2010 but not in Excel 2013.
See the attached images.
Comment 1 yeray alonso 2015-07-22 12:08:03 EDT
Created attachment 479 [details]
warning
Comment 2 yeray alonso 2015-07-22 12:08:25 EDT
Created attachment 480 [details]
error
Comment 3 yeray alonso 2015-07-22 12:10:13 EDT
Other export options work fine in Excel 2013; ie .ods gives the same recover alert, but it opens successfully after it.
Comment 4 narcís calvet 2015-08-04 10:02:36 EDT
The user in the URL field adds this also occurs with OpenDocument.
Comment 5 boris.seve 2015-08-04 10:25:02 EDT
When exported to ods I get the same error message and *some* data is recovered but the file is still incomplete.

I've attached an example in ods and straight text file.
Comment 6 boris.seve 2015-08-04 10:25:50 EDT
Created attachment 481 [details]
Export in ods

Some data can be recovered (one serie)
Comment 7 boris.seve 2015-08-04 10:27:06 EDT
Created attachment 482 [details]
Export in text format

With both series. The only thing suspicious I see that could explain the problem is the serie name containing multiple spaces
Comment 8 boris.seve 2016-01-27 10:47:40 EST
Same issue with Excel 2016. Did you manage to pinpoint what was the problem?
Comment 9 Jochen Burgstaller 2016-05-02 01:53:25 EDT
Is there something new in this case? I tried TeeChartVCLFMX-2016.17 with the latest excel version and it still tries to repair the file without success.
Comment 10 Gregor Kobler 2016-06-23 11:05:55 EDT
I just check the issue with the new version 2016.18.160504

The export to excel still not working!!
Comment 11 marc meumann 2016-09-02 11:51:58 EDT
A fix is currently being tested to be made available shortly.
Comment 12 boris.seve 2016-12-07 10:54:45 EST
Hello,

This is still broken in 2016.19, I've attached a sample file exported in the latest version.
Comment 13 boris.seve 2016-12-07 10:55:17 EST
Created attachment 676 [details]
Broken file, exported using v2016.19
Comment 14 marc meumann 2016-12-07 12:40:52 EST
Hello Boris, Yes, you're right, the fix isn't correctly applied to v2016.19. Apologies for the misinformation. Please confirm your contact details to sales at steema. com and we'll send a test version to you.
Comment 15 marc meumann 2017-03-09 10:01:31 EST
fixed for next update, March 2017.
Comment 16 boris.seve 2018-12-03 03:34:12 EST
Appears to be still broken in 2018.24.
Comment 17 yeray alonso 2018-12-07 03:28:39 EST
We are reviewing the export to .xls and will reply here as soon as possible.
Comment 18 yeray alonso 2018-12-12 06:35:55 EST
I've just applied a patch that seems to work for me here.

For those owning the sources, the change is at the beginning of the  TSeriesDataXLS.SaveToStream method in TeeStore.pas. Here the new part:

//////////////////////
Const BeginExcel : Array[0..1] of Word=(0,$09);
      EndExcel   : Array[0..1] of Word=($A,0);

var tt  : Integer;
begin
  Prepare;

  WriteBuf($09, 4);
  AStream.Write(BeginExcel, SizeOf(BeginExcel));

  if IncludeHeader then  //first unaltered line
//////////////////////