how do i limit the number of records on the detail section of a r.

G

Guest

i have a table of stores, products & sales value. each store can sell up to
500 products. i want to produce a report, grouped by store showing only the
top 15 products by sales value.

can anyone help?
 
D

Duane Hookom

One method is to add a text box to the detail section:
Name: txtCount
Control Source: =1
Running Sum: Over Group
Visible: No

Add code to the On Format event of the detail section:
Cancel = Me.txtCount >15
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top