Aerowolf
Programmer
- Nov 6, 2002
- 64
I have the following tables:
Categories with a Category field.
Types with Category and Type fields.
I have form Items with subform ItemCats.
In subform ItemCats I want the user to select the Category and then select the Type using combo boxes, but I want the Type combo box to be filtered based on the selection in the Category combo box.
Here's the code I have so far for the Type combo box:
SELECT [TYPES].[TYPE], [TYPES].[CATEGORY] FROM TYPES WHERE ((([types].[category])=[Forms]![ITEMCATSsubform]![CATEGORY])) ORDER BY [TYPES].[TYPE];
Why won't it work?
Thanks
Edwin
Categories with a Category field.
Types with Category and Type fields.
I have form Items with subform ItemCats.
In subform ItemCats I want the user to select the Category and then select the Type using combo boxes, but I want the Type combo box to be filtered based on the selection in the Category combo box.
Here's the code I have so far for the Type combo box:
SELECT [TYPES].[TYPE], [TYPES].[CATEGORY] FROM TYPES WHERE ((([types].[category])=[Forms]![ITEMCATSsubform]![CATEGORY])) ORDER BY [TYPES].[TYPE];
Why won't it work?
Thanks
Edwin