You are reading help file online using chmlib.com
|
Rave Reports Developer Reference TBaseReport. OnNewPage event (read/write/published) |
Top Previous Next |
Declaration procedure OnNewPage(Sender: TObject);
Category
Description This event will be called whenever a new page is generated. This can be useful to initialize page related items.
See also TBaseReport Class, NewPage, SelectBin
Example (Delphi) procedure TRpForm.RvNDRWriter1NewPage(Sender: TObject); begin with Sender as TBaseReport do begin PrintBitmapRect(0.5,0.5,1.20,1.20,Logo); MarginTop := 0.5; Home; SetFont('Arial',24); PrintHeader('Report Title', pjCenter); MarginTop := 1.0; Home; SetFont('Arial',10); PrintHeader(FormatDateTime(DateFormat, now), pjRight); end; { with } end;
Example (C++Builder) void __fastcall TRpForm:: RvNDRWriter1NewPage (TObject *Sender) { TBaseReport* rp = dynamic_cast<TBaseReport*>(Sender); rp1->PrintBitmapRect(0.5,0.5,1.20,1.20,Logo); rp1->MarginTop = 0.5; rp1->Home(); rp1->SetFont("Arial",24); rp1->PrintHeader("Report Title", pjCenter); rp1->MarginTop = 1.0; rp1->Home(); rp1->SetFont("Arial",10); rp1->PrintHeader(FormatDateTime("ddd, dd mmm yyyy hh:mm:ss", Now()), pjRight); } |
You are reading help file online using chmlib.com
|