Export data in test or xls format

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Dge
Newbie
Newbie
Posts: 6
Joined: Tue Mar 16, 2004 5:00 am

Export data in test or xls format

Post by Dge » Fri Aug 14, 2009 2:28 pm

Hi,

When I try to save data (a lot of series with addXY method), with this code:

with TSeriesDataXLS.Create(PhysicalChart,nil) do
try
includeindex:=false;
IncludeHeader := True;
IncludeLabels := false;
SaveToFile('bidon.xls');
finally
Free;
end;
with TSeriesDataText.Create(PhysicalChart,nil) do
try
textdelimiter:=';';
includeindex:=false;
IncludeHeader := True;
IncludeLabels := false;
SaveToFile('bidon.csv');
finally
Free;
end;

I cannot obtain the name of the 'X' series with TSeriesdataText and 'X' and 'Y' series name with TSeries DataXLS. For example see the head and the first line of my two files:

in TXT mode:
X V0 X V1 X V2
0.11 2.406738281 0.11 0.986157238 0.11 1.868481398

in XLS mode
X Y X Y X Y
0.11 2.406738281 0.11 0.986157238 0.11 1.868481398

I want to obrtain this in my file:

Time V0 Time V1 Time V2
0.11 2.406738281 0.11 0.986157238 0.11 1.868481398

Thank you for any help.

Gérard.

Yeray
Site Admin
Site Admin
Posts: 9602
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: Export data in test or xls format

Post by Yeray » Mon Aug 17, 2009 8:22 am

Hi Gérard,

If you have a name assigned to the X and/or to the Y value lists, they will be respected for the xls file, while the X name and the series name are used for the txt file. So you could try with that:

Code: Select all

  Chart1[0].XValues.Name := 'Time';
  Chart1[0].YValues.Name := 'V0';
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Post Reply