reporting autosearch criteria on the report
?In our app, based on the report explorer, in the header of most reports,
there is a memo, and in that memo are placed the non-default criteria
selected by the user. I've searched in vain for the mechanics behind this,
in reports where it works now, and have only approximated it with a system
variable on the form containing SearchDesc, but that doesn't appear to
support downward growth of the object, among other issues.
Can you point me in the right direction, either in doc, or wiki, or a demo
app?
Thanks!
--- posted by geoForum on http://www.newswhat.com
there is a memo, and in that memo are placed the non-default criteria
selected by the user. I've searched in vain for the mechanics behind this,
in reports where it works now, and have only approximated it with a system
variable on the form containing SearchDesc, but that doesn't appear to
support downward growth of the object, among other issues.
Can you point me in the right direction, either in doc, or wiki, or a demo
app?
Thanks!
--- posted by geoForum on http://www.newswhat.com
This discussion has been closed.
Comments
The System Variable simply assigns the TppReport.AutoSearchDescription
property to the text value. If you would like to accomplish the same thing
with a memo, you could access the same property.
See the TppSystemVariable.GetStandardValue inside the ppVar.pas file for how
this component functions.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
In reports where this has been added before I came into it, I see that if
I delete the memo, and try to preview, it throws an error. Also, if I put
such a memo in a report which has not had it, the connection is not made,
so it is not populated. Those two facts seem to suggest that the report
design itself contains a property somewhere which hooks up the memo for
this functionality.
Your reply seems to suggest I need to do something in code, but I'm not
aware of code in the app being specific to the individual reports....
--- posted by geoForum on http://www.newswhat.com
variable of the vtSearchDesc type.
--- posted by geoForum on http://www.newswhat.com
The only functionality in ReportBuilder that can automatically display the
search criteria on the report is the SystemVariable. Otherwise you need to
write some code.
Both of your comments indicate that the report contains either Delphi code
or RAP code that loads the Memo with the search criteria. Another
possibility is that you or someone else created a custom memo descendant
component.
--
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
solution in hand, but a problem remains.
In the Modules view, in the Event Handlers section, how do I bring a new
handler into existence? I right click in the list, and I see New in the
menu, but it's commented out. Is there a module I must register to get
this functionality?
--- posted by geoForum on http://www.newswhat.com
Not sure if I missed something here but we use a standard Memo component
(not a DBMemo) in the footer and in RAP code for the Memo.OnPrint event just
add:
Report.GetAutoSearchDescriptionLines(Memo1.Lines);
This populates the memo with text like this e.g.
"Show all data where the Surname begins with S and the Area is equal to 31"
This changes depending on the actual criteria entered at report run time.
Regards, Paul.
Thanks again!
--- posted by geoForum on http://www.newswhat.com