Error after Printing

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Alex
Newbie
Newbie
Posts: 10
Joined: Fri Nov 15, 2002 12:00 am

Error after Printing

Post by Alex » Thu Jul 08, 2004 10:36 am

Hi,
After printing a chart using the charteditor (it prints well) and closing the application dialog, debugger raises the following error:

" Project Project1.exe raised exception class EAccessViolation with message 'Access violation at address FFF40000. Read of address FFF40000 ".

I have a printer connected and it prints fine. The problem raises when closing the application ( Close(); ).

Thank you.
Alex

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Thu Jul 08, 2004 12:09 pm

Hi Alex,

does this happens in another app. ? Have you tried to create a simple app. with an ChartEditor and do the same (Print) ?
I cannot reproduce the problem here.

Alex
Newbie
Newbie
Posts: 10
Joined: Fri Nov 15, 2002 12:00 am

Post by Alex » Thu Jul 08, 2004 12:37 pm

With a simple App it does not happens.
I tried to print with:

Chart->BevelOuter = bvNone;
TColor OldColor = Chart->Color;
Chart->Color = clNone;
TMetafile *tmpMeta = Chart->TeeCreateMetafile(true,Chart->ClientRect);
try
{
Printer()->Orientation = poLandscape;
Printer()->BeginDoc();
Printer()->Canvas->StretchDraw(Rect(1,1,Printer()->PageWidth - 1,
Printer()->PageHeight - 1),tmpMeta);
Printer()->EndDoc();
}
__finally
{
delete tmpMeta;
Chart->BevelOuter = bvRaised;
Chart->Color = OldColor;
}

And the error doesn´t appear.
It only happens using Chart Editor.

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Thu Jul 08, 2004 6:14 pm

Hi Alex,

this happens in an old application ? If so, perhaps the problem is your old application is still referencing old TeeChart bpi/lib or obj files ? Before recompiling your old application, make sure it references/uses only new TeeChart packages.
If is not the case, can you post an example to the steema.public.attachments newsgroup with which I can reproduce "as-is" the problem here ?

Post Reply