query based on combo box on form not working. Coming back blank

P

Piperlynne

I am trying to run a report based off a query that uses a selection from a
combo box for the selection criteria. The criteria is below for the field
tblItem.ProjectStatus (the criteria is listed in the criteria cell in qry
design).

=[Forms]![frmReports]![StatusSrch]
When I run the query with the form open and a value selected, the query
returns no records. What am I missing?

I feel like I only know enough to get into trouble LOL HELP
 
J

Jeff Boyce

Often, a combobox will store the "lookedup value's" recordID, even though
the lookedup value is what is showing in the form.

But you said you are using "tblItem.ProjectStatus" -- the implication is
that you are using a TABLE-based lookup field, rather than a combobox on a
form. In that case, you have discovered one of the reasons why folks in
these newsgroups recommend AGAINST using the lookup data type!

My recommendation is to change the field data type back to whatever is
compatible with the underlying key field of the lookup table, then use a
combobox in a form to do the selection.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top