Result of queries

J

JL

I do not know where DoCmd keeps its return value. If it
does or not.
But I can suggest a alternative.

Using what you already have
(If the FACILITY_NUMBER is Number Type)
SQL = "FACILITY_NUMBER = " & FACILITY_COMBO.Column(0)

(If the FACILITY_NUMBER is Text Type)
SQL = "FACILITY_NUMBER = '" & FACILITY_COMBO.Column(0)
& "'"

Ctr = Dcount("FACILITY_NUMBER", "FACILITYMARKETTABLE", SQL)
It will store how many number matched FACILITY_COMBO.Column
(0) in variable Ctr.
 

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