findfirst - 2 search criteria

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

i wish to find a record based on 2 criteria, in this case i wish to search
for a particular job id and then date type as each job id could have a
multiple amount of date types.

rs.Findfirst "[Job ID] = " & aJob AND "[Date Type] = " &aDate

i am not sure how to program the AND.
 
liz said:
i wish to find a record based on 2 criteria, in this case i wish to
search for a particular job id and then date type as each job id
could have a multiple amount of date types.

rs.Findfirst "[Job ID] = " & aJob AND "[Date Type] = " &aDate

i am not sure how to program the AND.

It goes inside the quotes. You also need to delimit a date with #.

rs.Findfirst "[Job ID] = " & aJob & " AND [Date Type] = #" & aDate & "#"
 
Back
Top