There are several ways to do this. You can filter the report or use criteria
in the query feeding the report. Using the criteria, you can place the
criteria in the query as a parameter and let the query prompt for it or you
could use a pop-up form to prompt the user and let the query get the value
of the parameter from the form. The nice thing about the form is you could
use a combo box to let the user make their selection instead of relying on
them typing it in properly.
1) Create a form with a combo box. For the Row Source of the combo box, fill
in the locations by a value list or query.
2) Place two buttons on the form, Ok and Cancel.
3) If Ok is clicked, verify a value has been selected then hide the form
(Visible = False). If Cancel is selected, close the form.
4) In the query feeding the report, set the criteria for the location field
to the combo box on the form. (i.e. Forms!frmMyPopup!cboMyCombo)
5) In the Open event of the report, open the pop-up form with the acDialog
window mode argument in the DoCmd.OpenForm call. This will cause the code in
the report to pause until the pop-up form is closed or hidden. In the next
line, check to see if the form is open, if it isn't then the user chose
Cancel and you can also cancel the opening of the report.
6) Close the pop-up form when you close the report.
--
Wayne Morgan
Microsoft Access MVP
"Steve Patrick" <sp********@blueyonder.co.uk> wrote in message
news:lg********************@fe1.news.blueyonder.co .uk...
Hi All
You guys are my last hope, despite spending money on books and hours
reading
them I still can not achieve the results I need.
I have designed a database in Access 2000 based on 1 table, all has gone
very well with one exception. The table is based on applications made by
potential customers looking to buy franchise rights to particular
locations
and as part of the process they are asked to list their preferred
locations
1 to 4. The table I have designed and forms for inputting info, editing
info
are fine. I have even managed to design a form that lists applicants and
their preferred areas 1 - 4.
However I would like to design a process that says to the user "What area
are we opening in?" they input West London for example and this produces a
report that lists only the applicants that have applied for that area.
Sounds simple - but I have been trying to achieve this for over a week
now.
Please help.
Steve Patrick.