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

Reg. Traversing in Preview form

edited March 2005 in General
Hi all,

I have a report, populated thru' connecting to a pipeline that gets the data
from a kbmMemTable. Inside the report,on the Detail band beforeprint, I have
a piece of code which checks for a particular field value of the current
record and prints the label values accordingly.

for eg., Onbefore print of detail band

if then
begin
Label.Caption := plDetail['Value'];
end;

The issue is that the report prints correctly and shows the data in the
correct way when traversed from the first page to last page. However, when
traversed from the last page to the first page, it seems to repeat the last
record available in dataset. (Dataset value is not directly printed but the
label is printed based on the value in the dataset).

Printing the report to the printer also prints the data in the correct
order. Only when browsing from backwards (in the preview form) shows the
data incorrectly. Any suggestions

Thanks,
Swami

Comments

  • edited March 2005
    Hi Swami,

    Try setting the Report.CachePages property to True. This should solve the
    issue.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited March 2005
    That worked. Many thanks for the tip.

  • edited March 2005
    Hi,

    There seems to be one more issue. If the report has say 50 pages and if
    Cachepages set to True, when previewing if the user straightaway goes to the
    last page and starts traversing backwards the problem seems to persist.

    However, if it traversed from the first page to last page atleast once and
    from then on when traversing backwards it works fine. Any further tips.

    Thanks,
    Swami


  • edited March 2005
    Hi,

    Do you have a one or two pass report? If it is a one pass, try setting the
    Report.PassSetting to psTwoPass and see if that helps.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited April 2005
    Hi Nico,

    Setting the otherway round helped..Thanks for the Support.

    Regards
    Swami

This discussion has been closed.