Forum > LCL

lazreport - Is it possible to repeatedly print a number of records in LazReport

(1/1)

adilsonpazzini:
Is it possible to repeatedly print a number of records in LazReport?
for example, print 3 times the same record.

Cod.Parts   Description       $
00000001  AMORTECEDOR 10,00
00000001  AMORTECEDOR 10,00
00000001  AMORTECEDOR 10,00
00000002  BATERIA           11,00
00000002  BATERIA           11,00
00000002  BATERIA           11,00


Thank you very mach in advance .

Adilson Pazzini .

balazsszekely:
I assume you have a master or detail band, on it a memo. The band is linked to a query. You also have an OnEnterRect event for the frReport:

--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---procedure TForm1.frReportEnterRect(Memo: TStringList; View: TfrView);begin  if (View is TfrMemoView) then  begin    if (View as TfrMemoView).Name = 'MyMemo' then    begin     //you can add other conditions here      (View as TfrMemoView).Memo.Text := qMyQuery.FieldByName('MyField').AsString + sLineBreak +                                         qMyQuery.FieldByName('MyField').AsString + sLineBreak +                                         qMyQuery.FieldByName('MyField').AsString;    end;  end;end; You should change MyMemo, qMyQuery, MyField and you're good to go.

adilsonpazzini:
I thought maybe there was some property for that.

Thank you so much

Navigation

[0] Message Index

Go to full version