View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Pete_UK Pete_UK is offline
external usenet poster
 
Posts: 8,856
Default Month(A1) in 2007

Try this for month:

=TEXT(A1,"mmm")

if you just want the first 3 letters of the month, or:

=TEXT(A1,"mmmm")

if you want the full month name.

You can combine the month and year, like so:

=TEXT(A1,"mmm-yyyy")

to give you SEP-2009, for example.

Hope this helps.

Pete

On Sep 8, 12:54*pm, rexmann wrote:
Hi All

I am trying to get just the year and month of a date to display and I am using

=year(A1)
=month(A1)

the year is fine but the month appears as a number 1-12. I have tried
changing the field to custom month but this just give the wrong answer. I can
use a v-lookup to convert which is no problem but a bit messy (I remember in
2003 it worked fine)

Any suggestions greatly appreciated

cheers Rexmann