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

Basic RB report layout question

edited October 2003 in General
Hi.

I have an RB report that currently takes 3 pages. A good deal of this length
is because of memos, images, etc that may or may not contain text or image
content, but I've laid out the space assuming they do/might have content,
and I've set aside the space they are likely to need (but even so it might
not be enough and it might get cut off).

How do I get it so that, assuming I have a memo field, it uses up as much
space as it needs to fill out the memo text, but if there is no memo data,
it doesn't use any additional lines of space (ie there is never more than
one empty line)?

Also, suppose I wanted the memo layout space available to be arbitrarily
long, but of a fixed width. That is, the dbmemo would adjust to become as
deep as required to fit in all the text, pushing everything else down the
page below it.

How do I do these things?

Thanks!

Lauchlan M

Comments

  • edited October 2003

    Luchan:

    You need to use a Region component to accomplish your spacing. Region
    components contain memos, graphics, etc. & dynamically expand to meet the
    space requirements of their components.

    In your report, you could have Region1
    Region2
    Region3

    Region2.ShiftRelativeTo = Region1
    Region2.Strech = True

    Region3.ShiftRelativeTo = Region2
    Region3.Strech = True

    I believe that if the components in the region are set visible=False
    then the region will contract to a height of 0.

    Check out the help on regions and check out the Demos.


    Neil Huhta
  • edited October 2003
    Hi

    I am using regions anyway, to organise my report components. But if I have
    say a dbmemo in the region which for the sake of argument is spaced to take
    up the bottom half of the region, it still takes that same space regardless
    of whether there is one word or 10 paragraphs in the dbmemo. Setting the
    dbmemo (or a region containing the dbmemo) to false will not achieve the
    aim, because it still needs to be visible to display its one word, even if
    it doesn't need space for 10 paragraphs in this given case.

    So I'm not sure what the next thing I need to do is. Before I get the
    regions moving relative to each other, I've got to figure out how to resize
    the regions depending on the data in its components for a given record, and
    before that how to resize how much space the components use depending on the
    amount of data in the components, and make adjacent components shift
    accordingly.

    Thanks!

    Lauchlan M
  • edited October 2003
    Lauchlan:

    Use 1 Region for each horizontal area you need to size - maybe even 1
    region per memo control. Size the memo control to only hold 1 line & set the
    memo stretch property to true. The memo will expand within the region. The
    regions will stay positioned vertically one after another.

    Is this what you are trying to do ???


    Neil Huhta
  • edited October 2003
    Check the Band properties that these components reside on and make sure that
    the PrintHeight is set to 'phDynamic'.

    Regards,
    Chuck
This discussion has been closed.