Stuff AutoSearch values into a template
I'm trying to stuff Autosearch values for a report stored in an Oracle
database and executed on a server from a thin client Delphi EXE call.
I can do this for a local report, attached to the form. What's the process
when the report is stored in a database?
What I'm trying to do is get the same report to run from 3 different
directions, albeit a little different depending on where it's called from...
1> Via the WEB, user will be prompted by AutoSearch for criteria. (Performs
well)
2> Via an Explorer to the server, again user will be prompted by Autosearch.
(Couldn't be easier)
3> From a client.exe to the server where I stuff in Autosearch values
collected off a form on the client.exe BEFORE the report is ever called
without screwing up option one and two. I read how to do this someplace in
the last 24 hours and I can't find it!
Thanks - Jon Gray
database and executed on a server from a thin client Delphi EXE call.
I can do this for a local report, attached to the form. What's the process
when the report is stored in a database?
What I'm trying to do is get the same report to run from 3 different
directions, albeit a little different depending on where it's called from...
1> Via the WEB, user will be prompted by AutoSearch for criteria. (Performs
well)
2> Via an Explorer to the server, again user will be prompted by Autosearch.
(Couldn't be easier)
3> From a client.exe to the server where I stuff in Autosearch values
collected off a form on the client.exe BEFORE the report is ever called
without screwing up option one and two. I read how to do this someplace in
the last 24 hours and I can't find it!
Thanks - Jon Gray
This discussion has been closed.
Comments
in the autosearch demo directory which show how to modify the search
criteria at runtime for reports stored in an end user database.
This was posted in the Server newsgroup. Is this what you were lookign for:
-------------------------------------------
ClentReport: Customizing AutoSearch
-------------------------------------------
There are two approaches to customizing autosearch when using the
ClientReport component.
a. Customize the built-in autosearch dialog in the same manner as
applies to a standard TppReport (see RBuilder\Demos\AutoSearch\Custom
AutoSearch Dialog).
b. Use the ClientReport.OnReceiveAutoSearchFieldsEvent. This event fires
when the client report receives autosearch fields from the server. In
the event-handler, you can programmatically set the search values. You
can optionally set ShowAutoSearchDialog to False to suppress the
autosearch dialog and then call PrintToDevices to send the autosearch
values to the server.
example:
ClientReport1.AutoSearchFields[0].ShowAllValues := False;
ClientReport1.AutoSearchFields[0].SearchExpression := 'A';
{optional code to suppress the autosearch dialog and generate the
report}
ClientReport1.ShowAutoSearchDialog := False;
ClientReport1.PrintToDevices;
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com