=IF($D6>=AprStart,$D6<=AprEnd)

S

s2m

When I use this formula to count 1 or 0 if column D dates fall between the
dates, it shows False or True.

How do I get it to show 1 or 0?

Thanks
 
R

Ron Coderre

When you use a Boolean formula (a formula that returns TRUE or FALSE), Excel
returns those values. Their numeric equivalents are 1 and 0, respectively.
BUT...to coerce the conversion from Boolean to Numeric, you need to apply an
arithmetic operator. The generally accepted convention is to use a double
minus sign (--). Knowledgable Excel users immediately recognize the purpose
of -- in a formula.

Try this:
=--IF($D6>=AprStart,$D6<=AprEnd)

OR..this works too:
=--OR($D6>=AprStart,$D6<=AprEnd)

Does that help?
***********
Regards,
Ron

XL2002, WinXP
 
B

Bob Phillips

The second should be AND, OR gives 1 whatever the value.

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)
 
Top