count records on form

R

richard harris

i have a form which holds two fields (chk box) recommended and chosen.

the query then filters all records that are recommended for a particular
client. i have then at the foot of the form created a total of recommended,
no problem.

i have also totaled the chosen, but access is counting all records and not
those chosen. i cant use the query as it will filter out the unchosen
records but i still need them.

for example, 5 products recommended and 3 chosen. the foot of the form
should read 5 and 3, but is reading 5 and 5. any help please

and thanks

richard
 
C

Cinzia

richard harris said:
i have a form which holds two fields (chk box) recommended and chosen.

the query then filters all records that are recommended for a particular
client. i have then at the foot of the form created a total of recommended,
no problem.

i have also totaled the chosen, but access is counting all records and not
those chosen. i cant use the query as it will filter out the unchosen
records but i still need them.

for example, 5 products recommended and 3 chosen. the foot of the form
should read 5 and 3, but is reading 5 and 5. any help please

and thanks

richard

Hi Richard,
you can use the Dcount function: DCount("IDProduct"; "Products";
"Choosen=-1")
Bye
 
Top