像這種要求比較特殊的報表,用手動建造比較好控制
procedure Page1OnManualBuild(Sender: TfrxComponent);
const
MaxRow=6;
var
i:integer;
row:integer;
begin
with Report.getdataset('frxDBDataset1')do
begin
row:=0;
first;
while not eofdo
begin
Engine.ShowBand(MasterData1);
row:=row+1;
if row mod MaxRow =0 then
begin
Engine.ShowBand(PageFooter1);
Engine.Newpage;
end;
next;
end;
for i:=1 to (MaxRow-(row mod MaxRow))do
Engine.ShowBand(MasterData2);
end;
end;
;