correct formulation of expression in control source

  • Thread starter Thread starter LP
  • Start date Start date
L

LP

How can I combine 2 expressions that use the DCount function?
For example, in control source,
=DCount("[Field1]","qryX","[Field1]=True") will give me a value Y which I
need to add to another value obtained by
=DCount("[Field1]",qryZ","[Field1]=True").
I have tried various bits such as =DCount("[Field1]","qryX" And
"qryZ","[Field1]=True") but that does not work.
Can anyone help?
Regards
 
Have you tried

=DCount("[Field1]","qryX","[Field1]=True") +
DCount("[Field1]",qryZ","[Field1]=True").


--
John Spencer
Access MVP 2002-2005, 2007-2008
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 
Many thanks for this John
Regards
LP

John Spencer said:
Have you tried

=DCount("[Field1]","qryX","[Field1]=True") +
DCount("[Field1]",qryZ","[Field1]=True").


--
John Spencer
Access MVP 2002-2005, 2007-2008
Center for Health Program Development and Management
University of Maryland Baltimore County
..

LP said:
How can I combine 2 expressions that use the DCount function?
For example, in control source,
=DCount("[Field1]","qryX","[Field1]=True") will give me a value Y which I
need to add to another value obtained by
=DCount("[Field1]",qryZ","[Field1]=True").
I have tried various bits such as =DCount("[Field1]","qryX" And
"qryZ","[Field1]=True") but that does not work.
Can anyone help?
Regards
 
Back
Top