Drawing image On AfterPage
I just tried to draw an image direct in the OnAfterPage event -> works great
but : on the last page, the event isn't called why ?
My Code :
procedure TForm1.ppGroupFooterBand1AfterPrint(Sender: TObject);
var
temp : TppDrawImage;
begin
temp := TppDrawImage.Create(nil);
temp.Page := ppReport1.Engine.Page;
temp.Left := ppReport1.PrinterSetup.PageDef.mmMarginLeft;
if doOabe then
temp.Top := ppReport1.PrinterSetup.PageDef.mmMarginTop - 25400
else
temp.Top := ppReport1.PrinterSetup.PageDef.mmMarginTop;
temp.Width := ppReport1.PrinterSetup.PageDef.mmPrintableWidth;
temp.Height := 25000;
temp.Stretch := TRUE;
temp.Transparent := TRUE;
temp.Picture.LoadFromFile('C:\kopf.gif');
temp.Transparent := TRUE;
end;
but : on the last page, the event isn't called why ?
My Code :
procedure TForm1.ppGroupFooterBand1AfterPrint(Sender: TObject);
var
temp : TppDrawImage;
begin
temp := TppDrawImage.Create(nil);
temp.Page := ppReport1.Engine.Page;
temp.Left := ppReport1.PrinterSetup.PageDef.mmMarginLeft;
if doOabe then
temp.Top := ppReport1.PrinterSetup.PageDef.mmMarginTop - 25400
else
temp.Top := ppReport1.PrinterSetup.PageDef.mmMarginTop;
temp.Width := ppReport1.PrinterSetup.PageDef.mmPrintableWidth;
temp.Height := 25000;
temp.Stretch := TRUE;
temp.Transparent := TRUE;
temp.Picture.LoadFromFile('C:\kopf.gif');
temp.Transparent := TRUE;
end;
This discussion has been closed.
Comments
The problem was, that the Group wasn't printed on the last page
Now i put it into to EndPage and it works great (except the transparent
image problem ... one post above)