I have a known SubReport (CommentsSubReport) with only the Detail band (ppDetailband1). I would like to populate the band with a series of TppLabel at runtime. How would I do this correctly?
Adding a component to a report in code is simply a matter of creating the component, assigning its mandatory properties (top, left, height, width, caption), and finally assigning its Band property. This all needs to be done before the report is printed.
Comments
Adding a component to a report in code is simply a matter of creating
the component, assigning its mandatory properties (top, left, height,
width, caption), and finally assigning its Band property. This all
needs to be done before the report is printed.
lLabel := TppLabel.Create(Self);
lLabel.Caption := 'My Label';
lLabel.Top := 1.5;
lLabel.Left := 1.5;
lLabel.Width := 2;
lLabel.Height := 0.5;
lLabel.Band := ppReport.DetailBand;
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Thanks for the code snippet. It helped.
Andy