Ajit S Fernando Ajit S Fernando - 6 months ago 11
SQL Question

Dropdown list in MS Access from a query

I have a valid query in MS Access which pulls data from a linked table. But when I use this query as a row source for a combo box in a form, no data is pulled and the list is empty. What can be the problem?

The Query:

SELECT tbl_activityList.ActivityCategory
FROM tbl_activityList
WHERE (((tbl_activityList.ActivityTeam)=[Forms]![frm_everydayTasks]![lbl_teamName]))
GROUP BY tbl_activityList.ActivityCategory;


The Datasheet view, when the query is run:

The Datasheet view, when the query is run:

The property box:

The property box:

Answer

Simple.. I just modified the SQL query. Instead of [Forms]![frm_everydayTasks]![lbl_teamName] I used Me.lbl_teamName.Caption and its working fine. Thanks.

Comments