Make list available dependent on selection of another field

  • Thread starter Thread starter PsyberFox
  • Start date Start date
P

PsyberFox

Hi again!

I have a list of reasons which the user must select on an input screen
(form). There are however reasons in this list pertaining to a departmental
option of another field. Is it possible to make certain values in this list
available based on the selection of a department? Or would it be better to
try and link more than one table into this field as a lookup list, but also
based on the selection of a department? (I'm not sure how to do the latter
either)...

Thank you very much for any help!
 
Hi PsyberFox,

"Is it possible to make certain values in this list available based on
the selection of a department? "

yes

do this:

use a query to limit the list as you like, pulling data from the
multiple tables it will need and, initially, manually specify a
particular department in the criteria

once the query is working as you wish, change the specific criteria to a
control reference on a form (that form must be open when you test the
query)

forms!formname!controlname

WHERE
formname is the name of the form
controlname is the Name of the control for department on the form

~~

now, use this query as the RowSource of your listbox

when you update the control that contains department, use the department
AfterUpdate event to requery the listbox with the following code

me.listbox_controlname.requery


Warm Regards,
Crystal

Access Basics
8-part free tutorial that covers essentials in Access
http://www.accessmvp.com/Strive4Peace/Index.htm

*
(: have an awesome day :)
*
 
Back
Top