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

report hanging when printing

edited October 2004 in RAP
Hi,

can you tell me where to look for a sollution for the next problem:

in our aplications whe use the reportexplorer and designer

when opening the explorer for the first time and opening a report to screen.
it shows the first page correct. When pressing the last page button the
cursor changes in the hourglas and ... nothing happens. (the same when
printing). If i do the same again whitout leaving the explorer it works
correct. If i leave the explorer and go to the same report the same happens.
This happens in several reports.

where are using rbuilder 7.04 wih delphi 7 and direct oracle access.

thanx in advance

Ruud

Comments

  • edited October 2004
    Hi Ruud,

    Are you able to move through the pages of your report one by one? Does this
    behavior happen with every report you try to run using DOA and oracle? Try
    creating a very simple report with a single dataset and no events and see if
    the same behavior occurs. Also, try this with our DOA demo located in the
    RBuilder\Demos directory.

    --
    Regards,

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

    Best Regards,

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

    No, i can not move through my pages one by one. When i klick on the next
    page button the same thing happens.

    The report's i.am having trouble with do all have an onopen event on the
    tppDBPipeline in witch a modal window is opend and the user can select on
    something. The sql in the doad is changed en refreshed.
    when i make a simple report from the same datapipeline and
    torraclewwdataset, no grouping only 1 dbfield. the same happens.
    The changing of the sql seems to work correct. The first page is show
    acording the new sql.
    Although nothing happens and the hourglass is shown the cancel button stil
    works.

    When i include the rbuilder source directory in the search path i can see it
    go through the
    spbPreviewLastClick event (unit rbPrvDlg) after F7 it goes to
    FormCallWndProcHook (pptp97) code 0.
    and does this again and again endless...

    I tried the demo program, that worked correct.

  • edited October 2004
    Hi Ruud,

    Try placing a stop in the OnOpen event and see how many times this is fired.
    I believe this may be where the problem is occuring. As an alternative, you
    might try changing the SQL code before you load the report, separating this
    process from ReportBuilder as far as possible. You may need to create a
    custom report explorer so you can gain control over the click and open
    events of the dialog. When you run the app without the explorer, which
    event are you using to change the SQL?

    --
    Regards,

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

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited October 2004
    Hello Nico,

    I took out the modal form in the on open event and changed it to:

    odtsmutations.SetVariable('STARTDATE',now-200);
    odtsmutations.SetVariable('STOPDATE',now);
    odtsmutations.refresh;

    The behaviour stayed the same: When clicking the last button there are no
    calls to oracle etc. The cursor changes and thats that.
    Experimenting with the value of the variables i discovered that when the sql
    initialy has no records this strange behaviour occurs. When the sql initialy
    contains 1 or more records everything works correct. This is why the reports
    only went wrong the first time!

    To speed up things i always fill variables initially so that the sql does
    not return any records. Then in the on open event i fill the variables and
    then run the sql again (refresh).

    Can you think of an a way, maybe an event, i can fire to let this work the
    way i do now. I realy, realy , realy, want to let the dialog happen on the
    onopen event of the pipeline. This way i can present several pipelines to
    the enduser and the correct dialog is fired if the the pipeline is connected
    in the report.

    thanx\ks in advance

    Ruud



  • edited October 2004
    Hi Ruud,

    I did some searching through the RB source and it looks like the pipeline is
    checking for records in your dataset just before the OnOpen event is called.
    Since you are waiting until then to fill your dataset, the pipeline still
    thinks there are no records available. As a test, try calling the
    TppDataPipeline.UpdateState method after you fill your dataset inside the
    OnOpen event and see if that makes a difference.

    --
    Regards,

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

    Best Regards,

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

    calling the datapipeline.UpdateState method made no difference, any other
    suggestions?

    kind regards

    Ruud


  • edited October 2004
    Hi Nico,

    i found an acceptrable work around!!!: If i keep the dataset closed until
    the datapipeline dialog is finished everything works the way i want. Thank
    yoy very mutch for the support.

    Kind regards

    Ruud


This discussion has been closed.