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

AutoSearchfield

edited June 2003 in End User
Hi,

We are using RBuilder 7.02 Enterprise / Delphi 7 / SQL Server 2000

We store the reports in the database, and for now, there is not a single
report written in code.
To have different parameter windows for different reports, I have written
different parameter windows, so I can register the correct one in the
beginning, and de-register it at the end.
This works fine!

Now, I want to have a checkbox in my parameter windows which let the user
check if he only needs to see the summary, or the whole report.
Here is my problem: how can i add this checkbox since it is not related to
any database field?
When closing the parameter form, I fill in all autosearch fields, but can I
fill in some kind of report-variable i can use afterwards to check if i need
to preview/print the whole report or just the summary ???

I can do this with 2 different windows, but why give the user 2 windows if i
can bundle it to 1 parameter window. Since I only use RAP, i don't see any
solution yet.

Any help would be appreciated.

Regards,
Wouter Devos
XLent Solutions

Comments

  • edited June 2003
    Sounds like you just need to code a custom form from scratch at runtime that
    is built dynamically using a class registry, much like our custom autosearch
    dialog does. The exception is that you are using report parameters, not
    autosearch, and you also need the ability to add a custom checkbox. You'll
    have to construct all of this such that there is an abstract method or
    extract an interface form each class which creates UI controls (as in a
    factory) in order to provide the checkbox support on one dialog with
    parameters making the rest of the UI for this custom form. Then the best bet
    is to show this form from RAP in a RAP pass through function using the
    global OnCreate event.


    Cheers,

    Jim Bennett
    Digital Metaphors


  • edited June 2003
    Jim,

    Indeed, I created my own AutoSearchDialog with all the stuff I need. It is
    not generate panels for each autosearch parameter, but I have different
    forms for different reports. We only needed to create some forms to run all
    our reports, so this works very good.
    My problem was that I needed to have a report parameter instead of an
    autosearch parameter.

    When showing this form in RAP, do I need to set ShowAutoSearchDialog to
    false? I suppose so, otherwise I get the form twice?

    Regards,
    Wouter Devos


  • edited June 2003
    Ah, it is an autosearch dialog. Yes, you can show this form manually, and
    then in assign its OnClose event, you'll have to transfer the entered field
    values to the autoserach field values manually. This is the same event
    you'll need to use in order to assign the entered report parameters too.

    ShowAutoSearchDialog will need to be false.


    Cheers,

    Jim Bennett
    Digital Metaphors


This discussion has been closed.