Hi,
I am using RadStudio Alexandria and would lile to runtime create a chart and export it to a PDF file. Is it possible to be done without using a form with a TChart component on by simply creating a TChart instance together with TSeries instances?
Many thanks in advance!
Kind Regards
John
Runtime creating chart with PDF export in a simple unit
Re: Runtime creating chart with PDF export in a simple unit
Hello John,
This seems to work fine for me here:
This seems to work fine for me here:
Code: Select all
uses Chart, Series, TeePDFCanvas;
procedure TForm1.Button1Click(Sender: TObject);
var Chart1: TChart;
begin
Chart1:=TChart.Create(Self);
Chart1.View3D:=False;
Chart1.AddSeries(TLineSeries);
Chart1[0].FillSampleValues;
TeeSaveToPDFFile(Chart1, 'test.pdf');
end;
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |