Computing.Net > Forums > Office Software > Comparing Dates in Excel

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Comparing Dates in Excel

Reply to Message Icon

Name: Dee Jay
Date: May 5, 2009 at 02:59:57 Pacific
OS: Windows XP
Subcategory: Microsoft Office
Comment:

Hi,

Please help me in comparing dates in Excel.
Let the cells have dates as given below...
A2 = 10-Jan-2009
B2 = 20-Feb-2009
C2 = 30-Mar-2009.

I need a formula that checks if C2 is equal to any of the dates given in A2 or B2.

I tried with this and got an error but could not get it right... :(
=IF(C2= A2 OR B2, "Equal", "Not Equal")



Sponsored Link
Ads by Google

Response Number 1
Name: Mike (by mmcconaghy)
Date: May 5, 2009 at 06:38:26 Pacific
Reply:

Try This:

1st - Highlight Column Data Cells
I.E. Cells A1 thru A100

On the Menu Bar:

2nd - Format
3rd - Conditional Formatting
4th – Change “Cell Value is” to “Formula Is”
5th – Enter the formula:

=COUNTIF($A$1:$A$100,A1)>1

Sub Menu Format :
6th - Patterns
7th - Choose a pretty color
8th - Press OK
9th - Press OK

Duplicate records should now be highlighted in your selected pretty color.

Too go along rows up to the letter D use this:

1st - Highlight Column Data Cells
I.E. Cells A1 thru D1

change formula to:

=COUNTIF($A$1:$D$1,A1)>1

MIKE

http://www.skeptic.com/


0

Response Number 2
Name: Bryco
Date: May 5, 2009 at 07:02:42 Pacific
Reply:

=IF(OR(C2=A2,C2=B2),"Equal","Not Equal")

If C2 equals A2 or if C2 equals B2 then Equal, else Not Equal.

Bryan


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Office Software Forum Home


Sponsored links

Ads by Google


Results for: Comparing Dates in Excel

Formating dates in excel www.computing.net/answers/office/formating-dates-in-excel/8732.html

Subtracting Dates in Excel www.computing.net/answers/office/subtracting-dates-in-excel/8894.html

Two Different dates in Excel 2000 www.computing.net/answers/office/two-different-dates-in-excel-2000/3442.html