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

Autosearch Previrew Button

edited April 2003 in Server
I'd like the Autosearch preview button to appear in the viewer even tho I'm
programmatically filling the Autosearch fields in the
OnReceiveAutoSearchFields event and disabling "ShowAutoSearchDialog". If I
leave it enabled I get both the report displayed and the autosearch panel on
top of it.

Any Ideas?

Thanks! - Jon Gray

RB 7.02 Server based with trsClientReport.

Comments

  • edited April 2003

    For RB 7.02, the ClientReport has a new GetAutoSearchParameters method that
    can be used to accomplish this....

    -----------------------------------------------------------
    Tech Tip: ClientReport - Default AutoSearch Expression
    -----------------------------------------------------------

    The ClientReport.GetAutoSearchParameters method can be used to retrieve

    Report.AutoSearchFields[] fields from the report server. You can then assign
    the

    AutoSearchField.SearchExpression value and call the print method.


    As an example, add the following code to the
    RBServer\Demos\Clients\ClientReport example.



    {----------------------------------------------------------}

    procedure TfrmClientReport.btnPrintClick(Sender: TObject);
    begin

    {set the volume and report name}
    rsClientReport1.VolumeName := 'Report Files';
    rsClientReport1.ReportName := 'Customers\Orders\Order List';

    {retrieve the autosearch paramters from the server and set the default
    search expression}
    if rsClientReport1.GetAutoSearchParameters then
    rsClientReport1.AutoSearchFields[0].SearchExpression := 'S';

    rsClientReport1.Print;

    end;



    --
    Tech Support mailto:support@digital-metaphors.com
    Digital Metaphors http://www.digital-metaphors.com




    --
    Nard Moseley
    Digital Metaphors
    http://www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.