Referencing year portion of date

A

Allison

Excel 2003 SP2
Win XP SP3

I want to compare today's year with a 4-digit number to see if they are the
same.

I tried formatting a cell as "yyyy" and then using =now(). This DISPLAYS
the year, but if I try to compare it to the number I get a mismatch.

Ultimately, I want to display "Updated" in a cell, if today's year is the
same as the 4-digit number in the reference sheet.

I'd prefer a formula over VBA code, but beggars can't be choosers, right? =)

I'd appreciate any pointers to get me started in the right direction. Thank
you.
 
A

ArthurJ

A B
1 3/1/2005 =year(A1)=A$5 False
2 10/5/2008 True
3 4/9/2003 False
4
5 2008

Enter the formula shown in cell B1 and copied it down.
It will evaluate as shown.

Art
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top