custom parameters demo -
I have a number of questions concerning how the report templates (rtm files)
like the ones shown in the RBServer custom parameters demo were created.
AutoSessionReport
- memSearchDesc
How and from where is the memSearchDesc being generated? I have
yet found a way to alter this in the demo.
How is the SQL statement being modified to accept the form parameter? I am
assuming that it is from the
lsCompanySearchExpression :=
aWebRequest.AutoSearchParameters[0].Fields[0].SearchExpression
Is this correct, and if so, how would one go about changing the search
criteria field? (i.e. SELECT * FROM Customers WHERE Contact LIKE C%)
Where can I get more information on using the AutoSearchParameters?
like the ones shown in the RBServer custom parameters demo were created.
AutoSessionReport
- memSearchDesc
How and from where is the memSearchDesc being generated? I have
yet found a way to alter this in the demo.
How is the SQL statement being modified to accept the form parameter? I am
assuming that it is from the
lsCompanySearchExpression :=
aWebRequest.AutoSearchParameters[0].Fields[0].SearchExpression
Is this correct, and if so, how would one go about changing the search
criteria field? (i.e. SELECT * FROM Customers WHERE Contact LIKE C%)
Where can I get more information on using the AutoSearchParameters?
This discussion has been closed.
Comments
1. Each of the example reports contains RAP event-handler code (RAP is the
run-time Pascal environment included with RB Enterprise. Using RAP enables
the code to be stored as part of the report definition (i.e. stored in the
.rtm).
Note: If you have not used RAP before, check out the RAP tutorials in the
Developers Guide, the demos installed to RBuilder\Demos\RAP and the RAP.hlp
installed with RB).
2. To edit the reports...
Open the custom parameters server project. Then open the
rbReportTemplateVolume.pas unit and place a TppReport component on the
datamodule. Access the Report Designer and then use File | Open to open each
of the .rtm files. To view the RAP code, access the Calc workspace and
select View | Module (or select View | Events).
Note: Delete the TppReport from the datamodule prior to closing it. In a
typicaly environment I recommend using a separate project to edit the
reports.
3. Parameter passing
Parameters are defined on by the server and by the reports that run on the
server. Parameter passing between the server, and webtier are handled for
you.
View the code and read the comments for the rbServerForm.pas unit and the
the rbReportTemplateVolume.pas unit.
Note: In the rbReportTemplateVolume.pas the event-handler methods have an
aEventParams object. This object contains access to the TppReport instance
and to the Session parameters, etc. See the RBServer.hlp for documentation
TrsReportTemplateVolume and then select the events and then select the
related topics.
4. AutoSearch
If the RB Data Workspace is used to define the AutoSearch parameters then
the entire process handled automatically for you: parameter passing, web
form generation, sql modification, etc.
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com