Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Band Height proportional to lines in ppMemo

edited May 2003 in General
I am building a report that groups on a particular value in my data file.
Each group can have any number of lines within the detail. Rather than
build up to 100 or more sub reports to handle each different group, I
decided to put a ppmemo field on the group detail band. This way I can add
as many lines as needed. I also put a ppshape on the band so that I can
change the color of every other row on the report. I set the Stretch
property of the ppmemo field to true and the PrintHeight property of the
band to phdynamic. Don't know if it affects anything, but I set the
ParentHeight and Width properties of the ppshape to True so that the shape
will grow with the band.

When I print the report, the band does not re-size itself based on the
number of lines in the ppmemo. I have one group that is supposed to have
two lines. It does print both lines in there, but it reduces the font size
so that it can fit them in the band. Is there a way to have the height of
the band grow proportionally with the number of lines I have in the ppmemo?

Comments

  • edited May 2003
    Richard,

    Try setting the StretchWithParent property to True. This force the
    non-stretchable controls to stretch with the particular band that it is in.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2003
    Thank you for the suggestion. I went in to try what you suggested, however,
    the only thing that has a StretchWithParent property is the shape. I tried
    setting this, but it made no difference.

    I forgot to mention that I am using v7.01 of Report Builder Pro and Delphi
    6. Don't know if that makes a difference.

  • edited May 2003
    I figured out that the problem was with the ppMemo field properties. I had
    the Leading property set to zero, so when it stretched to show the second
    line, there was no space between the two lines. By adjusting the Leading
    property, I have been able to get the lines in the ppMemo to print like I
    want.

This discussion has been closed.