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

Cancel dialog won't close

edited August 2003 in General
Hi,
I have a custom preview form with a ppViewer and when I call the viewer's
Print function it prints fine, but the Cancel Dialog won't close. It seems
to be a specific problem with my reports and my custom preview. If I call
print from the default RB preview it works ok. What TppX class is
responsible for this cancel dialog? Any clue why this is happening?

Thanks.
Morten

Comments

  • edited August 2003
    I modified the custom preview form tutorial to call Viewer.Print and it
    works fine in tests here. Can you send an example to
    support@digital-metaphors.com that shows the problem? Do you have any other
    code that would be causing an infinite loop during the report generation?
    The cancel dialog is created when you call Report.Print. The report ancestor
    (TppProducer in ppProd.pas) creates the cancel dialog.

    Cheers,

    Jim Bennett
    Digital Metaphors


  • edited August 2003
    Thanks Jim,

    I found the problem. Each of my reports were connected to a TppSubReport for
    composite printing, this in addition to being able to stand alone (for
    customization). Removing the TppSubReport logic made the cancel dialog
    behave correctly. I assume that the Cancel Dialog was waiting for the
    TppSubReport item to finish, and not the actual TppReport that was being
    printed.

    Morten

This discussion has been closed.