Home DADE

AutoSearchDialog doubt!

edited November 2002 in DADE
Hi !
We are having some problems and we need some help !
After I've created the AutoSearchDialog , I would like to set an initial
value for the search criteria in runtime.
For example , I've a Grid with many records , and when I call the Report
from this form , I would like to initialize the search values with some
informations from the current record . So the user do not have to include in
the filter the current record informations..... But he can change it if he
whant's !
I'm modifying this value in the TdaSQL , changing the specific
SelectCriteria value.
But I can't recreate or refresh the autosearch dialog with this
modifications.....

I don't know if you could understand what I mean, since my English is not
very good !!!!
Any help is welcome !

Thanks in advance ,

Lucas

--

Comments

  • edited November 2002
    The problem is that you need to set this criteria value earlier. If you are
    loading templates, then use the public Report.Template.OnLoadEnd event to
    extract the SQL object and modify the dataview's criteria object's value.
    Then you should see that new value when the dialog is created.

    Another option if you aren't using templates, is to create a custom
    autosearch dialog to populate the edit box with a record from the pipeline.
    Here is an example of a custom autosearch dialog with lookups which is
    related (although maybe more data intensive) to what you are asking.

    http://www.digital-metaphors.com/tips/CustomAutosearchDialog.zip


    Cheers,

    Jim Bennett
    Digital Metaphors

This discussion has been closed.