When embedding quotes, you have to do something "special" so that Access/VBA
know that you intend to embed the quotes and not that the end of the line
comes sooner. As you have it written, Access thinks that the quote between
the = and the F is the end of the line and it doesn't know what to do with
the remainder. To let Access know that you really intended to embed the
quotes, you need to double them.
Try:
=Dcount("*";"Table1";"Isnull([dpt]) and left([Call];1)=""F""")
--
Wayne Morgan
MS Access MVP
"F6GGR" <no****@wanadoo.fr> wrote in message
news:44***********************@news.wanadoo.fr...
Hello,
I use Access 2000 and i want to use the Dcount function in a form.
I try to build this expression in a texte zone : I tried many ways usuing
and mixing " and/or ' but Access always says "Error" !
=Dcount("*";"Table1";"Isnull([dpt]) and left([Call];1)="F"")
This is to count the number of record(s) where the field [dpt] is empty
AND the field [Call] begins with the F letter.
[dpt] and [Call] are two fields of table1.
Could you help me ?
73 from F6GGR