View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Function or formula to convert "text" month to number of month?

=text(date(2007,a1,1),"mmm")

if A1 contained the number (1-12).

Jennnifer wrote:

Does anoyone know how to do the reverse. Convert month number to text.

Ex: 1 = Jan, 2= Feb

"Steve Vincent" wrote:

Is there a function to convert the text name of a month (e.g., "April") to
its corresponding number (e.g., "4")? If not, the only workaround I can
think of would be a long, nested IF function (e.g., =IF(A1="January",
"1",IF(A1="February", "2", . . . etc. . . ))))))))

TIA for any help offered,
Steve


--

Dave Peterson