View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default Nested Ages Plus or Minus (IF)


Test this
=IF(OR(B2=C2,B2=C2+1,B2=C2-1),"y","N")

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Douglas Eckert" wrote in message
...
I used the following formula to ask MS Excel to compare two age fields to
see
if they are within one year (plus or minus) of matching each other. (It
returned all "NO" answers, which was incorrect).

=IF(((B2=C2)*OR(B2=C2+1)*OR(B2=C2-1)*OR(B2+1=C2)*OR(B2-1=C2)),"YES","NO")

'Suggestions, please?