对呀——你是怎么设置的,为什么不行呢???
我给你的就是求得qrlabel的高度,然后下一行的qrlabel的top就是qrlabel.top+GetTextHeight(qrlabel);了啊
到底是什么意思???我晕了~~~~
你qrlabel放到哪里的,detailband里???
detailband的onbeforeprint里写呢:
procedure TForm2.DetailBand1BeforePrint(Sender: TQRCustomBand;
var PrintBand: Boolean);
var
s,i:integer;
begin
s:=0;
for i:=DetailBand1.ControlCount-1do
wnto 0do
if DetailBand1.Controls is TQRLabel then
if s<(DetailBand1.Controls as TQRLabel).Height then
s:=(DetailBand1.Controls as TQRLabel).Height;
{ for i:=DetailBand1.ControlCount-1do
wnto 0do
if DetailBand1.Controls is TQRLabel then
if (DetailBand1.Controls as TQRLabel).Height<s then
(DetailBand1.Controls as TQRLabel).Height:=s;
}
Sender.Height:=s;
end;