R
Robert
I have a select statement that I need to run in code. The select statement
needs to reference 2 variables which are in the code. I know that the usual
way to run a select in code is with DLookup. This if fine because I only
need 1 column of 1 record even though the select can return more than 1
record. But, the query needs to reference those 2 variables in the code.
How can I run a select in code which references 2 fields in the code and get
the result of 1 record (only)? If necessary I could put those 2 values in
textboxes on forms as I have several queries which reference textboxes on
forms but is there a way to do it directly in the code?
Robert
needs to reference 2 variables which are in the code. I know that the usual
way to run a select in code is with DLookup. This if fine because I only
need 1 column of 1 record even though the select can return more than 1
record. But, the query needs to reference those 2 variables in the code.
How can I run a select in code which references 2 fields in the code and get
the result of 1 record (only)? If necessary I could put those 2 values in
textboxes on forms as I have several queries which reference textboxes on
forms but is there a way to do it directly in the code?
Robert