Do it on the dataset. Show a simple dialog before you print the report to ask the user to see a Top or Bottom N report. Depending on which database you have, there are different functions to facilitate this. You'll have to check you database's documentation to find out what the function is (if one exists). For example, in SQL Server, you can say SELECT TOP 10 ...
If you're databse doesn't support this kind of aggregate function to limit the data, then you can also limit the data by using the DataPipeline properties to set the range to only return the first 10 records. You'll have to order the data by the field that you want the Top or Bottom N to be. You can also traverse the data pipeline from first to last or last to first. Please see the installed demos in the main 1. Reports demo project for an example of data traversal settings.
Comments
ask the user to see a Top or Bottom N report. Depending on which database
you have, there are different functions to facilitate this. You'll have to
check you database's documentation to find out what the function is (if one
exists). For example, in SQL Server, you can say SELECT TOP 10 ...
If you're databse doesn't support this kind of aggregate function to limit
the data, then you can also limit the data by using the DataPipeline
properties to set the range to only return the first 10 records. You'll have
to order the data by the field that you want the Top or Bottom N to be. You
can also traverse the data pipeline from first to last or last to first.
Please see the installed demos in the main 1. Reports demo project for an
example of data traversal settings.
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com