Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default Logical Test on Date value

I'm using the IF function and want the logical test to check whether a date
value is greater than another date; I can do this if I store the 2nd date in
another cell but would like to type directly into the formula. I've tried
B301/01/2008 in several different ways and also used the date function as
part of the logical test but it does not return the correct result.

Is there a trick to this or do I have to refer to another cell for dates? No
problem with doing this I just think I should be able to do it 'directly'
Thanks for any help (I'm using 2007 but the same result occurs in 2000)
Sheila
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7,247
Default Logical Test on Date value


Try using the DATE function to convert year, month, and day to an
actual date. E.g.,

=IF(A1DATE(2008,11,23),"A1 is greater","A1 is not greater")


Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
The San Diego Project Group, LLC
(email is on the web site)
USA Central Daylight Time (-5:00 GMT)


On Thu, 25 Sep 2008 10:50:10 -0700, Sheila D
wrote:

I'm using the IF function and want the logical test to check whether a date
value is greater than another date; I can do this if I store the 2nd date in
another cell but would like to type directly into the formula. I've tried
B301/01/2008 in several different ways and also used the date function as
part of the logical test but it does not return the correct result.

Is there a trick to this or do I have to refer to another cell for dates? No
problem with doing this I just think I should be able to do it 'directly'
Thanks for any help (I'm using 2007 but the same result occurs in 2000)
Sheila

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can I use 'CONTAINS' in an IF Logical Test? MichaelRobert Excel Worksheet Functions 3 April 2nd 23 08:11 PM
Using a logical test on a date is failing Les Thompson Excel Worksheet Functions 7 March 22nd 07 05:55 PM
Logical test retiredguy New Users to Excel 2 January 27th 07 05:56 PM
Logical Test Lance Excel Worksheet Functions 1 March 16th 06 09:26 PM
Logical test Sooraj Excel Discussion (Misc queries) 2 January 25th 05 12:59 PM


All times are GMT +1. The time now is 02:45 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"