ShiftWithParent & ReprintOnOverflow
Hi,
I have a subreport where the detail band contains the following component
types (in this order):
TppVariable,
TppDBText,
TppVariable,
TppDBMemo (Stretch = true),
TppVariable,
TppVariable
When I set all variables and the DBText component to ReprintOnOverflow, when
the report comes to a page break, the first 4 components behave as expected
if the memo stretches, but the last 2 variables print on both the previous
page and the next page. Is there a way I can fix this?
Thank you.
I have a subreport where the detail band contains the following component
types (in this order):
TppVariable,
TppDBText,
TppVariable,
TppDBMemo (Stretch = true),
TppVariable,
TppVariable
When I set all variables and the DBText component to ReprintOnOverflow, when
the report comes to a page break, the first 4 components behave as expected
if the memo stretches, but the last 2 variables print on both the previous
page and the next page. Is there a way I can fix this?
Thank you.
This discussion has been closed.
Comments
Try placing the two bottom variables inside a TppRegion and set the region
to ShiftRelativeTo the stretching memo. This should give you the effect you
are after.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
with regard to the variables shifting properly with the memo field. I'm now
trying to set the ShiftWithParent flag on one of the TppVariables at
runtime. What I would like to do is set this flag to true if a certain
condition is met. If I set it to true at design time, the variable will
appear even with the last line of the memo field, which is what I want to
achieve only when this condition is met. I've tried putting code into the
following TppVariable events:
OnCalc
OnPrint
OnDrawCommandCreate
OnFormat
None of this has worked. The variable I'm dealing with resides inside a
region which also contains the memo field. Here's the code I'm writing for
the events mentioned.
var
x:Integer;
begin
x := roaDetailPipeline.GetFieldValue('TRANSTYPE');
if (x > 0) and (x < 3) then
ppVariable17.ShiftWithParent := true
else
ppVariable17.ShiftWithParent := false;
end;