Page 1 of 1
AV on multipage chart print
Posted: Mon Jan 14, 2008 4:03 pm
by 10046826
I'm getting an AV when I attempt to print a multi page chart. My code just calls the ChartPreview function and the AV happens after OK on the select printer dialog.
I tried the feature in the demo app (Tee8New) and it also bombed. Is this a known problem or am I missing something ?
Delphi 7 + Teechart Pro 8.01.10798
Posted: Mon Jan 14, 2008 4:13 pm
by narcis
Hi GL123,
Could you please try if including OpenGL unit as described on
this thread solves the problem at your end?
If it doesn't, would you be so kind to send us a simple example project we can run "as-is" to reproduce the problem here?
You can either post your files at news://
www.steema.net/steema.public.attachments newsgroup or at our
upload page.
Thanks in advance.
Posted: Mon Jan 14, 2008 4:34 pm
by 10046826
Thanks. I tried adding the OpenGL unit but no luck.
I've uploaded a simple test app on the upload page. TeeChartTestApp.zip.
Posted: Thu Jan 17, 2008 2:05 pm
by narcis
Hi GL123,
Thanks for the example project. We have been able to reproduce this issue here and added it as a high priority defect in the bug list (TV52012736) to be fixed for next releases.
Posted: Thu Jan 17, 2008 3:31 pm
by 10046826
narcis wrote:Hi GL123,
Thanks for the example project. We have been able to reproduce this issue here and added it as a high priority defect in the bug list (TV52012736) to be fixed for next releases.
Thanks. Can you suggest
any sort of workaround before then? I need to release my software on Monday and this has just been raised as an issue
Posted: Sun Jan 20, 2008 11:15 pm
by 9047589
Try draw your charts onto Printer's canvas.
This code draws two charts side by side below the mid of the page
Code: Select all
var
PX, PY, OrgY, OrgX : Integer;
R: TRect;
MetaF : tMetaFile;
begin
PX:=Printer.PageWidth div 100;
PY:=Printer.PageHeight div 100;
OrgX:=PX*8;
OrgY:=PY*6;
YourChart1.Printing:=True;
MetaF:=YourChart1.TeeCreateMetafile(True,Rect(0,0,313,217));
R:=Rect(OrgX,PY*50,PX*49,PY* 70);
_Canvas.StretchDraw(R,MetaF);
MetaF.Free;
YourChart1.Printing:=False;
YourChart2.Printing:=True;
MetaF:=YourChart2.TeeCreateMetafile(True,Rect(0,0,313,217));
R:=Rect(PX*57,Py*50,PX*98,PY* 70);
_Canvas.StretchDraw(R,MetaF);
MetaF.Free;
YourChart2.Printing:=False;
Posted: Tue Mar 17, 2009 9:37 am
by yeray
Hi GL123,
We've tested this issue with the actual sources and we aren't able to reproduce this problem. Could you please try if the latest version available to download (v8.04) solves this for you?