Revision to a query

RaunLGoode

Registered User.
Local time
Today, 07:45
Joined
Feb 18, 2004
Messages
122
I want to write a script to add a criteria to an existing query.
I am using the following code based to look for the selection of an option button and executed “On Click” from a command button .
If optEmpNum.Value = True Then
qryEmpData. EmpNum.Criteria = [EnterValue for EmpNum]
End If

I get an error message “(DB Name) cannot find the field (I) referred to in your expression” The character between the parentheses (I) actual appears to be a straight line.

Is the correct way to describe the object (Right term?) Queryname.Field.Critetia? If it isn’t what is right?

Also do I need to somehow need to insert this query argument into the query in the design view? How would I do that?
Running Access 2000 /Win2000

Thank you,
 
Last edited:
Raun,

Use the Search Utility here and look for "QueryDef", you'll find lots of
examples.

Wayne
 

Users who are viewing this thread

Back
Top Bottom