[mso] Re: Excel 2000 Formula problem

Actually, the problem occurs for me when using the Xdate functions. I was
looking for a simple way to check all dates for validity (including those
before Microsoft's darn 1900 date).  Ok, here is a "real" example:
A1 is text, and contains: 1832-11-31.  November has just 30 days.)

I can't use the date functions to check that with. But I can break it up
like this:
B1 = value(left(A1,4))
C1=value(mid(A1,6,2)
D1=value(right(A1,2))
E1=Xdate(B1,C1,D1)
Fails, so I know the date is faulty. Caveat: I do not want date to roll-over
to the next month making it correct by using 1832-12-01 instead.

Or, I could do this:
B1 = value(left(A1,4))+2000
C1=value(mid(A1,6,2)
D1=value(right(A1,2))
E1=date(B1,C1,D1)

Same caveat- the date for me rolls over to the next month, making a "good"
date out of this. What I am trying to do is find questionable dates so I can
write the source for verification. I don't want to convert questionable
dates by rolling over.  Does that help? Or put another way, if I have:
A1 contain '1795-21-30  (as text)

What can I do to have Excel tell me I should question that? Does that help?

Thanks.

Robert

-----Original Message-----
From: mso-bounce@xxxxxxxxxxxxx [mailto:mso-bounce@xxxxxxxxxxxxx]On Behalf Of
Steve Moghaddam
Sent: 2007-03-31 12:08
To: mso@xxxxxxxxxxxxx
Subject: [mso] Re: Excel 2000 Formula problem

Your formula is correct. I tried my own, then I copied your formula and it
works.
The only thing was the date was shown as Roman and I changed the cell format
to show months/day/year.
Please try it again and this time make sure that the format on a1,b1 and c1
are numbers not text.
With respect to number of "and" test, I have used up to 12 to perform
summation. What function are you trying to use?
Thanks


-----Original Message-----
From: mso-bounce@xxxxxxxxxxxxx [mailto:mso-bounce@xxxxxxxxxxxxx] On Behalf
Of Robert Carneal
Sent: Friday, March 30, 2007 9:57 PM
To: mso@xxxxxxxxxxxxx
Subject: [mso] Excel 2000 Formula problem

Hello. I have a problem with a DATE assemblage formula that I am missing. I
get #VALUE! As the result.

Please assume:
A1=1932
B1=7
C1=20
And in D1 I have this formula:
=IF(AND(A1<>0,B1<>0,C1<>0),DATE(A1,B1,C1),"Check date")

Which I want to result in a display of 1932-07-20. It results in #VALUE!
Instead. Does my mistake pop out at anyone?

In another cell, I tried:
=DATE(1932,7,20)
and that works just fine. It shows 1932-07-20.

Yes, I know if the numbers were:
A1=1732
B1=7
C1=20
Instead, the date function would not work. I am working another way to
handle the dates before Microsoft's date birth.

Another question: In Excel 2000, is there a max tests I can put with AND ??
For example, could I use nine tests with AND?

Thank you.

Robert

*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or
MicrosoftOffice@xxxxxxxxxxxxxxxx

To send mail to the group, simply address it to mso@xxxxxxxxxxxxx

To Unsubscribe from this group, visit the group's homepage and use the
dropdown menu at the top.  This will allow you to unsubscribe your email
address or change your email settings to digest or vacation (no mail).
http://www.freelists.org/webpage/mso

If you are using Outlook and you see a lot of unnecessary code in your email
messages, read these instructions that explain why and how to fix it:
http://personal-computer-tutor.com/abc3/v28/greg28.htm
*************************************************************

*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or
MicrosoftOffice@xxxxxxxxxxxxxxxx

To send mail to the group, simply address it to mso@xxxxxxxxxxxxx

To Unsubscribe from this group, visit the group's homepage and use the
dropdown menu at the top.  This will allow you to unsubscribe your email
address or change your email settings to digest or vacation (no mail).
http://www.freelists.org/webpage/mso

If you are using Outlook and you see a lot of unnecessary code in your email
messages, read these instructions that explain why and how to fix it:
http://personal-computer-tutor.com/abc3/v28/greg28.htm
*************************************************************

*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or 
MicrosoftOffice@xxxxxxxxxxxxxxxx

To send mail to the group, simply address it to mso@xxxxxxxxxxxxx

To Unsubscribe from this group, visit the group's homepage and use the dropdown 
menu at the top.  This will allow you to unsubscribe your email address or 
change your email settings to digest or vacation (no mail).
http://www.freelists.org/webpage/mso

If you are using Outlook and you see a lot of unnecessary code in your email 
messages, read these instructions that explain why and how to fix it:
http://personal-computer-tutor.com/abc3/v28/greg28.htm
*************************************************************

Other related posts: