各位大侠如题是关于fastreport的报表打印中怎样在一页上打印固的行数,多余的行数新起一页打印,不足的用空行补足。如进货单编号20130512中共有12条单据,需要分两页打印、有6条信息时就在一张单据上打印再补充两行空行,求实现方法?delphi fastreport
解决方案 »
- 分享《delphi全掌握》很好的学习资料
- 问个关于Canvas 的问题....
- delphi中的application的hint属性有什么用,在哪显示的?请知道的大虾,告知一声!
- Multiple connections not supported by mysql driver问题
- 请问怎么样才能做一个象google那样有关edit输入时出现提示信息的功能?
- 数据库打包,注册表要写那几个键?
- problem 2 about print
- 如何记录当天电脑开机的次数?谢谢
- 关于计时问题
- 为什么我安装FlatStyle控件时总是出现这样的错误:[Fatal Error] FlatStyle_D5.dpk(54): Internal error: URW3010--,不是知道是什么原因,我试过好多次了,都是一样的,请帮我解答一下,谢谢!!
- 如何定位图像的坐标?
- d7怎么取得adoconnection.connectionstring中的服务器
var
PageMaxRow: integer=19;//行数
procedure Footer1OnBeforePrint(Sender: TfrxComponent);
begin
PageMaxRow:=19;
if <Page>=<TotalPages> then
begin
PageMaxRow:= PageMaxRow-strtoint(<DataLines>) mod PageMaxRow;
if PageMaxRow>0 then
begin
child1.visible := True;
Engine.ShowBand(Child1);
end;
child1.visible := False;
end;
end;procedure ReportSummary1OnBeforePrint(Sender: TfrxComponent);
var
i: integer;
Memo1: TfrxMemoView;
begin
PageMaxRow:=19;
if <Page>=<TotalPages>-1 then
if strtoint(<DataLines>)mod PageMaxRow=0 then
begin
PageMaxRow:=PageMaxRow-2;
if PageMaxRow>0 then
begin
while i < PageMaxRow do
begin
i := i + 1;
Memo1:= TfrxMemoView.Create(ReportSummary1);
Memo1.Text := ' <';
Memo1.Height :=Memo2.Height+3;
Memo1.width:=400;
Memo1.left:=10;
Memo1.top:=Memo2.Height*2+i*Memo1.Height+5;
Memo1.Align :=baNone;
end;
end;
end; if <Page>=<TotalPages> then
begin
Memo25.text:='------------ CLOSED ------------';
if strtoint(<DataLines>)mod PageMaxRow=0 then
begin
PageMaxRow:=PageMaxRow-2;
end
else
begin
PageMaxRow:= PageMaxRow-strtoint(<DataLines>)mod PageMaxRow;
PageMaxRow:= PageMaxRow-3;
end;
if PageMaxRow>0 then
begin
while i < PageMaxRow do
begin
i := i + 1;
Memo1:= TfrxMemoView.Create(ReportSummary1);
Memo1.Text := ' <';
Memo1.Height :=Memo2.Height+3;
Memo1.width:=400;
Memo1.left:=10;
Memo1.top:=Memo2.Height*2+i*Memo1.Height+5;
Memo1.Align :=baNone;
end;
end;
end;
end;procedure PageFooter1OnBeforePrint(Sender: TfrxComponent);
begin
if <Page>=<TotalPages> then
Memo25.text:='------------ CLOSED ------------';
end;beginend.
其中DataLines是程序传进来的变量就是数据总行数
添加Memo2,Memo25,PageFooter1,ReportSummary1控件
还需要自己琢磨下把