Access - Sorting in a dropdown list
Thorliaf
Posted messages
24
Status
Member
-
Thorliaf Posted messages 24 Status Member -
Thorliaf Posted messages 24 Status Member -
Hello everyone,
I'm finishing up a project and I'm stuck on a problem that I think is easily solvable...
I would like to know how to restrict the choices in a dropdown list based on the selections made in the previous field.
Example: dropdown list 1 (materials category) = Paint or Coatings or Hardware
dropdown list 2 (materials) = Red paint, green paint... etc if category = paint
screws, nails... etc if category = hardware
Do I necessarily have to go through a macro???
I want to specify that these 2 fields are in a sub-form
Thanks in advance for your advice...
I'm finishing up a project and I'm stuck on a problem that I think is easily solvable...
I would like to know how to restrict the choices in a dropdown list based on the selections made in the previous field.
Example: dropdown list 1 (materials category) = Paint or Coatings or Hardware
dropdown list 2 (materials) = Red paint, green paint... etc if category = paint
screws, nails... etc if category = hardware
Do I necessarily have to go through a macro???
I want to specify that these 2 fields are in a sub-form
Thanks in advance for your advice...
Configuration: Windows XP Internet Explorer 7.0
4 answers
No, you can go through a selection query as long as you have prepared your restrictive fields, then link your query to another query, it's very common.
Uhmmmm and how do we do it??? :)
I am a complete self-taught person and I move forward as needed... actually, there are a lot of very simple things that I can't manage to do :)
I am a complete self-taught person and I move forward as needed... actually, there are a lot of very simple things that I can't manage to do :)
Do you have multiple tables or just one?
If multiple, you connect these tables by a common field.
For example, you have a table
clients profession
one profession tools
you connect professions from tables 1 and 2 and you can extract clients - tools through a selection query.
If multiple, you connect these tables by a common field.
For example, you have a table
clients profession
one profession tools
you connect professions from tables 1 and 2 and you can extract clients - tools through a selection query.
In fact, I have:
1) a table "detail materiaux" (which serves for a subform of the table "devis")
a/ with "N° materiaux"
...
2) a table "materiaux"
a/ with "N° materiaux" (key)
b/ with "Categorie materiaux"
...
3) a table "Categorie"
a/ with "N° categorie" (key)
b/ with "categorie"
...
2a being linked to 1a one to many
3a being linked to 2b one to many
I want to add a category field in my subform "detail materiaux" in order to restrict the available choices of "N° materiaux" according to the input in this category field...
Phew, I'm not sure if I was clear ^^
1) a table "detail materiaux" (which serves for a subform of the table "devis")
a/ with "N° materiaux"
...
2) a table "materiaux"
a/ with "N° materiaux" (key)
b/ with "Categorie materiaux"
...
3) a table "Categorie"
a/ with "N° categorie" (key)
b/ with "categorie"
...
2a being linked to 1a one to many
3a being linked to 2b one to many
I want to add a category field in my subform "detail materiaux" in order to restrict the available choices of "N° materiaux" according to the input in this category field...
Phew, I'm not sure if I was clear ^^