Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Get month() ie. October 4

Status
Not open for further replies.

nickjar2

Programmer
Jun 20, 2001
778
US
I am using Excel. I can get the Month(date) (obviously for October this will be 10) but how do I actuall get 'October' to return. I could set up an array that held the months of the year, but was wondering if there is an easier way.

Nick
 
Use a custom cell format mask of MMMM.

Format->Cells->Number(Tab)->Custom


Dave
 
Hi Dave,

Thanks 4 responding. I am not too hot with Excel so could u explain what that would do please?

Nick
 
Nick,

I believe your own thought of using an Array was on the right track ...except try using the "Choose" function.

The following formula will work for you ...copy it right from here...

=CHOOSE(MONTH(A1),"January","February","March","April","May","June","July","August","September","October","November","December")

Regards, ...Dale Watson dwatson@bsi.gov.mb.ca
 
Hi Nick!

To specify Dave's idea:

You need to right click on the cell(s) you want to format. From the pop-up menu choose Format Cells. Click on the Numbers tab. In the list box, choose Custom. In the text box type MMMM. Now the cell will take the date in the the cell and display only the month.

hth Jeff Bridgham
bridgham@purdue.edu
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top