[mso] Re: Date format in Excel
- From: "David Smart" <smartware@xxxxxxxxxxxxxxx>
- To: <mso@xxxxxxxxxxxxx>
- Date: Wed, 31 Oct 2007 08:53:59 +1100
Yes. I should have checked it more carefully. :-( Indeed, that short
formula is badly flawed. It gets 10, 11, 12, 13, 20 and 30 wrong.
Compensation for the 10, 20, 30 involves adding an extra "th" and pushing
the index calculation up by 1. Elimination of the 11, 12, 13 can be done by
a Boolean multiplication that converts 10-19 to 0, allowing them to be
treated the same as 10, 20 and 30. But the formula is now quite a bit
longer.
=TEXT(DAY(A1),"00")&INDEX({"th","st","nd","rd","th"},MIN(RIGHT(DAY(A1),1)*(INT(DAY(A1)/10)<>1),4)+1)&TEXT(A1,"
mmm yyyy")
Regards, Dave S
----- Original Message -----
From: "Rajesh V - Program Leader(BC) - SIS" <rajesh.v@xxxxxxxxxxxxxxxxxxx>
To: <mso@xxxxxxxxxxxxx>
Sent: Wednesday, October 31, 2007 12:29 AM
Subject: [mso] Re: Date format in Excel
> Thanks a ton Mr David. Your explanation is very clear. But the second =
> formulae which u had given is not providing the correct result. Try =
> giving the date as 13-oct-2007, the result given by the formulae is 13rd =
> oct 2007 which isn't correct. Rather it should be 13th oct 2007.
>
> Thanks a lot again.
>
> ___,,,,_{=F4=BF=F4}_,,,,___
> Thanks & Regards
> Rajesh V
>
> -----Original Message-----
> From: mso-bounce@xxxxxxxxxxxxx [mailto:mso-bounce@xxxxxxxxxxxxx] On =
> Behalf Of David Smart
> Sent: Tuesday, October 30, 2007 6:52 PM
> To: mso@xxxxxxxxxxxxx
> Subject: [mso] Re: Date format in Excel
>
> Aha, I see.
>
> When I do it in Excel 2003, it does not quite keep the format. My data=20
> entry is 01st Oct 2007, but the next cell has 2nd Oct 2007 (i.e. it =
> doesn't=20
> hold on to the leading zero).
>
> However, it is very neat. I didn't realise it would do that.
>
> But ... notice that the dates are left justified. I.e. Excel has not =
> stored=20
> them as dates, it's stored them as strings. This might or might not be=20
> important for what you're doing, but it certainly means that Excel =
> formats=20
> are not involved. Essentially, you can apply any format at all to it=20
> (currency, percentage, etc) and it'll still show you the string that has =
> a=20
> date in it.
>
> You can demonstrate to yourself that it's not a date by putting a =
> formula in=20
> another cell to add 1 to the date in your cell. You would expect to get =
> the=20
> next day (or the date serial number of the next day). Instead, you'll =
> get=20
> #VALUE!. Then try it on a cell with an actual date value in it.
>
> So, it's a nice thing that the drag handle does, but it isn't available =
> in=20
> the formatting.
>
> However, lots of people have developed their own solutions to this =
> problem=20
> using VBA or complex formulas. Do a Google search. This one is adapted =
>
> from a formula I found here:=20
> http://www.dailydoseofexcel.com/archives/2004/07/19/ordinal-days/ with=20
> thanks to David Wasserman who contributed the original formula.
>
> =3DTEXT(DAY(A1),"00")&IF(OR(MOD(DAY(A1)-1,10)>2,INT(DAY(A1)/10)=3D1),"th"=
> ,CHOOSE(MOD(DAY(A1),10),"st","nd","rd"))&TEXT(A1,"=20
> mmm yyyy")
>
> Hmmm, Stan Scott on the same page had a shorter version. Again, I've =
> added=20
> the bits to get the rest of the date
>
> =3DTEXT(DAY(A1),"00")&INDEX({"st","nd","rd","th"},MIN(RIGHT(DAY(A1),1),4)=
> )&TEXT(A1,"=20
> mmm yyyy")
>
>
>
> Regards, Dave S
>
> ----- Original Message -----=20
> From: "Rajesh V - Program Leader(BC) - SIS" =
> <rajesh.v@xxxxxxxxxxxxxxxxxxx>
> To: <mso@xxxxxxxxxxxxx>
> Sent: Tuesday, October 30, 2007 11:39 PM
> Subject: [mso] Re: Date format in Excel
>
>
>> Thanks for your reply Mr David
>>
>> See when we enter the date in excel as 01st Oct 2007 and use the fill
>> handle and drag it down, excel automatically recognises the series and
>> fills the same as 02nd oct 2007, 03rd oct 2007 etc. Hence I put forth =
> a
>> question that since excel is able to internally recognise the formats,
>> is there by any chance we change the format as above.
>>
>> When I enter the date as 01-oct-2007 and set an format to that, it
>> should change to 01st oct 2007.
>>
>> Hope I am clear now.
>>
>>
>> -----Original Message-----
>> From: mso-bounce@xxxxxxxxxxxxx [mailto:mso-bounce@xxxxxxxxxxxxx] On
>> Behalf Of David Smart
>> Sent: Tuesday, October 30, 2007 6:04 PM
>> To: mso@xxxxxxxxxxxxx
>> Subject: [mso] Re: Date format in Excel
>>
>> Sorry, not with you.
>>
>> What specific format does Excel recognise?
>>
>> What is the issue you have with changing the format?
>>
>> Regards, Dave S
>>
>> ----- Original Message -----=3D20
>> From: "Rajesh V - Program Leader(BC) - SIS"
>> <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>> To: <mso@xxxxxxxxxxxxx>
>> Sent: Tuesday, October 30, 2007 2:49 PM
>> Subject: [mso] Re: Date format in Excel
>>
>>
>>> Thanks for this advise. But excel recognises the format and when we
>> use
>>> the fill handle, it automatically generates the sequence in the way
>>> which I require. The only issue is when I want to change the format.
>>> Please advise
>>>
>>>
>>> -----Original Message-----
>>> From: mso-bounce@xxxxxxxxxxxxx [mailto:mso-bounce@xxxxxxxxxxxxx] On
>>> Behalf Of David Smart
>>> Sent: Tuesday, October 30, 2007 3:17 AM
>>> To: mso@xxxxxxxxxxxxx
>>> Subject: [mso] Re: Date format in Excel
>>>
>>> You can have the leading zero on the day without trouble. I think
>> that
>>> this=3D3D20
>>> is one of the standard date formats.
>>>
>>> I don't believe there is any built-in Excel facility that will give
>> you=3D3D20
>>> "st", "nd", etc.
>>>
>>> Regards, Dave S
>>>
>>> ----- Original Message -----=3D3D20
>>> From: "Rajesh V - Program Leader(BC) - SIS"
>>> <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>>> To: <mso@xxxxxxxxxxxxx>
>>> Sent: Tuesday, October 30, 2007 12:26 AM
>>> Subject: [mso] Date format in Excel
>>>
>>>
>>>> Hi All,
>>>> I need the date format in excel to be as 01st Oct 2007, 02nd Oct =
> 2007
>>>> etc. Is it possible to set any custom value . Please help.
>>>>
>>>> Thanks and regards
>>>>
>>>> Rajesh
>>>>
>>>>
>>>>
>>>> "Rajesh V - Program Leader(BC) - SIS" =
> <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>>>>
>>>>
>>>
>> =
> ________________________________________________________________________
>>> ___
>>>>
>>>> Visit us at www.sundaraminfotech.in
>>>>
>>>
>> =
> ________________________________________________________________________
>>> ___
>>>>
>>>> This E-mail may contain privileged information and is intended =
> solely
>>> for=3D3D20
>>>> the addressee, and any disclosure of this information is =3D
>> strictly=3D3D20
>>>> prohibited, and may be unlawful. If you have received this mail
>> by=3D3D20
>>>> mistake, please inform us immediately and delete this mail. =
> Any=3D3D20
>>>> information expressed in this mail does not necessarily reflect the
>>> views=3D3D20
>>>> of SUNDARAM INFOTECH SOLUTIONS. As per SUNDARAM INFOTECH
>> SOLUTIONS's=3D3D20
>>>> policy, unencrypted mail via Internet is not considered secure.
>>>>
>>>
>> =
> ________________________________________________________________________
>>> ___
>>>>
>>>> *************************************************************
>>>> You are receiving this mail because you subscribed to
>>> mso@xxxxxxxxxxxxx or=3D3D20
>>>> 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=3D3D20
>>>> address or change your email settings to digest or vacation (no
>> mail).
>>>> http://www.freelists.org/webpage/mso
>>>>
>>>> To be able to share files with the group, you must join our Yahoo
>>> sister=3D3D20
>>>> group. This group will not allow for posting of emails, but will
>>> allow=3D3D20
>>>> you to join and share problem files, templates, etc.:=3D3D20
>>>> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is
>> for
>>>
>>>> FILE SHARING ONLY.
>>>>
>>>> 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=3D3D20
>>>> it:
>>>> http://personal-computer-tutor.com/abc3/v28/greg28.htm
>>>> *************************************************************=3D3D20
>>>
>>> *************************************************************
>>> 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
>>>
>>> To be able to share files with the group, you must join our Yahoo
>> sister
>>> group. This group will not allow for posting of emails, but will
>> allow
>>> you to join and share problem files, templates, etc.:
>>> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is =
> for
>>> FILE SHARING ONLY.
>>>
>>> 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
>>> *************************************************************
>>> "Rajesh V - Program Leader(BC) - SIS" <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>>>
>>>
>> =
> ________________________________________________________________________
>> _=3D3D
>>> __
>>>
>>> Visit us at www.sundaraminfotech.in
>>>
>> =
> ________________________________________________________________________
>> _=3D3D
>>> __
>>>
>>> This E-mail may contain privileged information and is intended solely
>> =3D3D
>>> for the addressee, and any disclosure of this information is strictly
>> =3D3D
>>> prohibited, and may be unlawful. If you have received this mail by =
> =3D
>> =3D3D
>>> mistake, please inform us immediately and delete this mail. Any =
> =3D3D
>>> information expressed in this mail does not necessarily reflect the =
> =3D
>> =3D3D
>>> views of SUNDARAM INFOTECH SOLUTIONS. As per SUNDARAM INFOTECH =3D3D
>>> SOLUTIONS's policy, unencrypted mail via Internet is not considered =
> =3D
>> =3D3D
>>> secure.
>>>
>> =
> ________________________________________________________________________
>> _=3D3D
>>> __
>>> *************************************************************
>>> You are receiving this mail because you subscribed to
>> mso@xxxxxxxxxxxxx or=3D20
>>> 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=3D20
>>> address or change your email settings to digest or vacation (no =
> mail).
>>> http://www.freelists.org/webpage/mso
>>>
>>> To be able to share files with the group, you must join our Yahoo
>> sister=3D20
>>> group. This group will not allow for posting of emails, but will
>> allow=3D20
>>> you to join and share problem files, templates, etc.:=3D20
>>> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is =
> for
>>
>>> FILE SHARING ONLY.
>>>
>>> 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=3D20
>>> it:
>>> http://personal-computer-tutor.com/abc3/v28/greg28.htm
>>> *************************************************************=3D20
>>
>> *************************************************************
>> 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
>>
>> To be able to share files with the group, you must join our Yahoo =
> sister
>> group. This group will not allow for posting of emails, but will =
> allow
>> you to join and share problem files, templates, etc.:
>> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for
>> FILE SHARING ONLY.
>>
>> 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
>> *************************************************************
>> "Rajesh V - Program Leader(BC) - SIS" <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>>
>> =
> _________________________________________________________________________=
> =3D
>> __
>>
>> Visit us at www.sundaraminfotech.in
>> =
> _________________________________________________________________________=
> =3D
>> __
>>
>> This E-mail may contain privileged information and is intended solely =
> =3D
>> for the addressee, and any disclosure of this information is strictly =
> =3D
>> prohibited, and may be unlawful. If you have received this mail by =
> =3D
>> mistake, please inform us immediately and delete this mail. Any =3D
>> information expressed in this mail does not necessarily reflect the =
> =3D
>> views of SUNDARAM INFOTECH SOLUTIONS. As per SUNDARAM INFOTECH =3D
>> SOLUTIONS's policy, unencrypted mail via Internet is not considered =
> =3D
>> secure.
>> =
> _________________________________________________________________________=
> =3D
>> __
>> *************************************************************
>> You are receiving this mail because you subscribed to =
> mso@xxxxxxxxxxxxx or=20
>> 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=20
>> address or change your email settings to digest or vacation (no mail).
>> http://www.freelists.org/webpage/mso
>>
>> To be able to share files with the group, you must join our Yahoo =
> sister=20
>> group. This group will not allow for posting of emails, but will =
> allow=20
>> you to join and share problem files, templates, etc.:=20
>> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for =
>
>> FILE SHARING ONLY.
>>
>> 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=20
>> it:
>> http://personal-computer-tutor.com/abc3/v28/greg28.htm
>> *************************************************************=20
>
> *************************************************************
> 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
>
> To be able to share files with the group, you must join our Yahoo sister =
> group. This group will not allow for posting of emails, but will allow =
> you to join and share problem files, templates, etc.: =
> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for =
> FILE SHARING ONLY.
>
> 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
> *************************************************************
> "Rajesh V - Program Leader(BC) - SIS" <rajesh.v@xxxxxxxxxxxxxxxxxxx>
>
> _________________________________________________________________________=
> __
>
> Visit us at www.sundaraminfotech.in
> _________________________________________________________________________=
> __
>
> This E-mail may contain privileged information and is intended solely =
> for the addressee, and any disclosure of this information is strictly =
> prohibited, and may be unlawful. If you have received this mail by =
> mistake, please inform us immediately and delete this mail. Any =
> information expressed in this mail does not necessarily reflect the =
> views of SUNDARAM INFOTECH SOLUTIONS. As per SUNDARAM INFOTECH =
> SOLUTIONS's policy, unencrypted mail via Internet is not considered =
> secure.
> _________________________________________________________________________=
> __
> *************************************************************
> 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
>
> To be able to share files with the group, you must join our Yahoo sister
> group. This group will not allow for posting of emails, but will allow
> you to join and share problem files, templates, etc.:
> http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for
> FILE SHARING ONLY.
>
> 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
To be able to share files with the group, you must join our Yahoo sister group.
This group will not allow for posting of emails, but will allow you to join
and share problem files, templates, etc.:
http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for FILE
SHARING ONLY.
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
*************************************************************
- References:
- [mso] Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
Other related posts:
- » [mso] Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- » [mso] Re: Date format in Excel
- [mso] Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS
- [mso] Re: Date format in Excel
- From: David Smart
- [mso] Re: Date format in Excel
- From: Rajesh V - Program Leader\(BC\) - SIS