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

Re: Page Break

edited September 2003 in General
Greetings,

I am looking for a way to pagebreak from delphi code. What I am doing is
reading from a Blob and "want" to break when I come to a specific flag
already written in the data. Here's some psuedo code:

Readln from a BLOB
for i := 0 to blob.lines.count-1 do
begin
If Blob.Line.value='*pagebreak' then
begin
SetppComponentText('MyRTF',varData,ppReport1) RTF Component in
ppReport1
*** ppReport1.PageBreak *** or *** ppReport1.HeaderBand.PageBreak ***
end
else
varData := varData + Blob.lines.asvariant;
Readln from a BLOB
end;

My question to you is: Can I minipulate PageBreak from delphi code?

Thanks for your time in advance,
Tim Armstrong

Comments

  • edited September 2003
    Hi Tim,

    Check out the Band.OutOfSpace property to force a page break in code. This
    will cause the generator to think the page is out of space and go to the
    next page. Be sure that if you have a two pass report, the OutOfSpace calls
    match up for each pass or you will not get the correct output.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.