Approach User Support homepage Approach User Support
Answers to Frequently Asked Questions about Lotus Approach
Examples LotusScripts
Example databases
Links to other Lotus Approach support services

[Return to contents]

Including Find criteria on a report

Last updated: 3 Jan 2004 by XpertSS.com

The best way of doing this is to use one or more variable-type fields in the report header in a text block or as separate fields. These fields will not appear except in PrintPreview or when the report is printed.

For example, lets say that you have a Named Find/Sort that uses two variable fields to select records between two dates. The fields are named VarStart and VarEnd. The user fills in the fields and then runs a macro to go to the report. The header panel would have a text block containing the fields and text like this:

 Sales Report for <<VarStart>> thru <<VarEnd>>

You insert the fields into the text block not by typing them in as text, but by using the Text, Insert, Field Value method.

Another example might simply have your report macro set a variable field to the a description of the find criteria before the report is shown. A sample macro where a user has a radio button to select a value of ThisYear or LastYear:

View Report
 RUN If(userselect = 'ThisYear' run and return from FindThisYearMacro
      else run and return from FindLastYearMacro
 SET VarConditions = Combine('Report for ',If(userselect = 'ThisYear',Year(Today()),Year(today()) - 1))
 VIEW switch to report xxx
 PrintPreview

You would then put VarConditions in the header panel of your report.

[Return to contents]

© Copyright, JohnBrown, Trademarks, Disclaimer, Acknowledgements.