Select field to query based on Combo box

  • Thread starter jbair via AccessMonster.com
  • Start date
J

jbair via AccessMonster.com

I have 4 fields in a table NCAssy, NCParts, NCInspection, NCShipping and I
want to select which of those fields I want from a combo box called NCFields
and enter that field name into a query. I can easily do this with 4 queries
but want to do it with one by being able to choose which field I select.I
don't have any problems with the date selection. I know my expression is
wrong what do I need to fix it.?

SELECT [Forms]![TimsNCForm]![NCFields] AS Expr1, InspectionLog.PackDate
FROM InspectionLog
WHERE (((InspectionLog.PackDate) Between [Forms]![TimsNCForm]![Date1] And
[Forms]![TimsNCForm]![Date2]));

Thanks
JBair
 
Top