combo box filter

Lifeseeker

Registered User.
Local time
Today, 08:34
Joined
Mar 18, 2011
Messages
273
Hi,

I'm not sure if I've fallen into the trap of table level look up for this one, but I'm simply trying out a combo box filter that can be useful when it comes to data entry.

I have attached a copy.

Users will typically select a category, and depending on which category they select, the initiative combo box selection is filtered.

I have checked the code, but problem is that the initiative combo box is showing nothing.. Is this because I have a table level look up?

comment/help much appreciated.
 

Attachments

Yes, do NOT use lookups in tables!!! Your field in the Initiative table should be CATEGORYID and not CategoryName. And then the row source of your category combo should be:
SELECT Category.ID, Category.Category_Name FROM Category ORDER BY Category_Name;

And then the column count set to 2 and the column widths set to 0";1"

And then the Initiatives combo should have this as its row source:

SELECT Initiative.ID, Initiative.Initiative_Name FROM Initiative WHERE (((Initiative.Category_ID)=[forms]![Form1]![combo0])) ORDER BY Initiative.Initiative_Name;

And the column count set to 2 and the column widths set to 0";1"
 

Attachments

Yes, do NOT use lookups in tables!!! Your field in the Initiative table should be CATEGORYID and not CategoryName. And then the row source of your category combo should be:
SELECT Category.ID, Category.Category_Name FROM Category ORDER BY Category_Name;

And then the column count set to 2 and the column widths set to 0";1"

And then the Initiatives combo should have this as its row source:

SELECT Initiative.ID, Initiative.Initiative_Name FROM Initiative WHERE (((Initiative.Category_ID)=[forms]![Form1]![combo0])) ORDER BY Initiative.Initiative_Name;

And the column count set to 2 and the column widths set to 0";1"

Thank you very much Bob. It works like a charm
 

Users who are viewing this thread

Back
Top Bottom