Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Counting queries on a form

Status
Not open for further replies.

OC2

IS-IT--Management
Apr 2, 2001
59
SG
Hi,

I need to make a form that produces record counts based on multiple queries
ie
example
total orders = 220
orders received = 50
orders dispatched = 170

for total orders I use

=count([id])
this counts all the records

i have a field called transactiontype which states whether the order is received or dispatched

how do I perform a count for those.

ive tried
=count((([transactiontype])="s"))
but it doesnt work.

do you have any ideas?

also
id like to create a list box where a value select performs a count and displayed in a different text box.

can u also help on this one

thx a lot

Tom
 
Unless you have additional fields other than these totals on the form, you're probably better off making the form unbound (by erasing its Record Source property) and using the DCount() function to extract these totals from the table or tables. DCount(), like the other domain functions, let's you specify criteria for selecting the records to be counted. Rick Sprague
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top