When I export chart data to XLSX some data is lost and some data is offset. In the image attached you can see the values in the data table and what shows up after export. Any ideas how to correct the export.
Thanks
Mike Simmons
Data incorrect in export to XLSX
Data incorrect in export to XLSX
- Attachments
-
- DataExportIssue.jpg (281.02 KiB) Viewed 8064 times
Re: Data incorrect in export to XLSX
Hello Mike,
Would it be possible for you to save your chart as a .tee file when run (from editor, export binary include data) and send it to us, to [email protected] would be fine, and the xlsx exported file too? We'll load the chart and look for possible problems.
If you don't have an editor on the form the quickest way would be to add a TeeCommander bar temporarily for the test run.
With thanks,
Regards,
Marc Meumann
Would it be possible for you to save your chart as a .tee file when run (from editor, export binary include data) and send it to us, to [email protected] would be fine, and the xlsx exported file too? We'll load the chart and look for possible problems.
If you don't have an editor on the form the quickest way would be to add a TeeCommander bar temporarily for the test run.
With thanks,
Regards,
Marc Meumann
Steema Support
Re: Data incorrect in export to XLSX
Hi Marc,
I've sent the exported chart via email. Thanks for the fast response.
Mike
I've sent the exported chart via email. Thanks for the fast response.
Mike
Re: Data incorrect in export to XLSX
Hello Mike,
Thanks for the file. We can reproduce the output you've obtained, We see that the older format, xls, saves apparently correctly. We'll work our way through it.
I've logged it asa bug here: http://bugs.steema.com/show_bug.cgi?id=2513
Regards,
Marc
Thanks for the file. We can reproduce the output you've obtained, We see that the older format, xls, saves apparently correctly. We'll work our way through it.
I've logged it asa bug here: http://bugs.steema.com/show_bug.cgi?id=2513
Regards,
Marc
Re: Data incorrect in export to XLSX
Hi Marc,
I am allowing users to export data via a button click (see code below). I am apparently not triggering use of the older excel format. Can you direct me to a sample or the correct method?
Thanks,
Mike Simmons
procedure TGraphForm.DownloadDataAsXLX(Sender: TObject);
Var
NameOnly, DownloadFileName: String;
//XlsExp: TSeriesDataXLSObject;
XlsExp: TSeriesDataXLS;
begin
NameOnly := 'GRAPHDATA' + DM1.VUIUtil.MakeTimeStamp + '.XLS';
DownloadFileName := Noslash(G_Temp) + '\' + NameOnly;
try
xlsexp := TSeriesDataXLS.Create(Chart1);
//xlsexp := TSeriesDataXLSObject.Create(Chart1);
xlsexp.IncludeHeader := True;
xlsexp.IncludeIndex := True;
xlsexp.SaveToFile(DownloadFileName);
DM1.VUIUtil.DownloadFile(DownloadFileName, NameOnly);
finally
xlsexp.Free;
end;
end;
I am allowing users to export data via a button click (see code below). I am apparently not triggering use of the older excel format. Can you direct me to a sample or the correct method?
Thanks,
Mike Simmons
procedure TGraphForm.DownloadDataAsXLX(Sender: TObject);
Var
NameOnly, DownloadFileName: String;
//XlsExp: TSeriesDataXLSObject;
XlsExp: TSeriesDataXLS;
begin
NameOnly := 'GRAPHDATA' + DM1.VUIUtil.MakeTimeStamp + '.XLS';
DownloadFileName := Noslash(G_Temp) + '\' + NameOnly;
try
xlsexp := TSeriesDataXLS.Create(Chart1);
//xlsexp := TSeriesDataXLSObject.Create(Chart1);
xlsexp.IncludeHeader := True;
xlsexp.IncludeIndex := True;
xlsexp.SaveToFile(DownloadFileName);
DM1.VUIUtil.DownloadFile(DownloadFileName, NameOnly);
finally
xlsexp.Free;
end;
end;
Re: Data incorrect in export to XLSX
Hello Mike,
I'll check the syntax you have sent over in your last post, to run the older Excel version and reply to this thread. In the meantime just to let you know that issue you reported, logged as #2513, has been fixed.
I see you are a sourcecode customer so I am sending the modified unit to you directly. You should replace it in your source and run TeeRecompile to update the binary version and the vcl unit folder.
Regards,
Marc
I'll check the syntax you have sent over in your last post, to run the older Excel version and reply to this thread. In the meantime just to let you know that issue you reported, logged as #2513, has been fixed.
I see you are a sourcecode customer so I am sending the modified unit to you directly. You should replace it in your source and run TeeRecompile to update the binary version and the vcl unit folder.
Regards,
Marc
Steema Support
Re: Data incorrect in export to XLSX
Hello Mike,
This syntax works for earlier Excel format:
Regards,
Marc
This syntax works for earlier Excel format:
Code: Select all
type TSeriesAccess=class(TChartSeries);
procedure TForm1.Button2Click(Sender: TObject);
begin
with TSeriesDataXLS.Create(Chart1, nil) do
try
UseSeriesFormat := True;
IncludeHeader := True;
SaveToFile('d:\data\output\example.xls');
finally
Free;
end;
end;
Marc
Steema Support