Thread: customize date
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Teethless mama Teethless mama is offline
external usenet poster
 
Posts: 3,718
Default customize date

Ignore my previous post
Try this one:

=TEXT(A1,"mmmm
")&DAY(A1)&MID("thstndrdth",MIN(9,2*RIGHT(DAY(A1)) *(MOD(DAY(A1)-11,100)2)+1),2)&", "&YEAR(A1)



"enrico via OfficeKB.com" wrote:

i customized a cell with a now() date field so that it's date is always
updated. i also designed the cell and add a "th" word so that today would be
shown like this: 15th. what i miss is that the first to third day doesn't end
up with "th" but rather "st", "nd" and "rd" respectively. how will i
customize it that it will be flexible according to the date? (e.g. 1st, 2nd,
3rd, 4th, etc.)

--
Message posted via http://www.officekb.com