Page 1 of 1

print Chart + TImage

Posted: Mon Mar 06, 2006 11:17 am
by 9345071
Hi there,

just a quick question: is it possible to use the chart previewer and the chart printing funcitons (working very well :) ) to print my chart AND an image wich is over the chart in my form ?

(I use a timage instead of the tool image because i need to use events like OnMouse---...)

thank you

C.

Posted: Fri Mar 17, 2006 12:42 pm
by narcis
Hi Copeau,

You could try using something like the code below where Image1 is a TImage.

Code: Select all

procedure TForm1.Button1Click(Sender: TObject);
begin
  ChartPreviewer1.Execute;
end;

procedure TForm1.FormCreate(Sender: TObject);
begin
  Series1.FillSampleValues();
  Chart1.Draw;
end;

procedure TForm1.Chart1AfterDraw(Sender: TObject);
begin
  Chart1.Canvas.Draw(100,100,Image1.Picture.Graphic);
end;

Posted: Fri Mar 17, 2006 1:07 pm
by 9345071
hmmm
yes i'll try.

Can i do that just at print time, and clear it immediately after ?