Excel: MONTH Function Tip in Excel Documentation Is Incorrect
ID: Q74303
|
The information in this article applies to:
-
Microsoft Excel for Windows, versions 3.0, 4.0
-
Microsoft Excel for OS/2, version 3.0
-
Microsoft Excel for the Macintosh, versions 3.0, 4.0
SUMMARY
The MONTH function reference on page 279 of the version 4.0 "Microsoft
Excel Function Reference" (page 156 in the version 3.0 manual)
includes the following tip:
To display the result of the MONTH function as a month name, use
the Number command on the Format menu to format the cell containing
the function with the custom number format "mmmm".
Page 156 of the version 3.0 "Microsoft Excel Function Reference" also
includes the following example for the MONTH function:
TEXT(MONTH(367),"mmmm")
Both of these entries are incorrect. The MONTH function returns an
integer value from 1 to 12, based on the specified date.
MORE INFORMATION
To achieve the effect suggested in the tip in the manual, do one of
the following
- Use the one of the following formulas:
=TEXT(367,"mmmm")
Note: In the above example, 367 is the serial number of the date
1/1/01.
-or-
=TEXT(DATEVALUE("1/1/01"),"mmmm")
-or-
- Enter the date into a cell and format that cell with the custom
number format "mmmm".
The number format "mmmm" applies to a serial date number. The serial
numbers 1 through 12 correspond to the serial dates January 1, 1900
through January 12, 1900.
The TEXT function interprets this as a date between 1/1/00 and
1/12/00, based on the month in which the date falls. This date range
falls completely within the month of January so the TEXT function, as
used in the example above, will always return "January."
REFERENCES
"Microsoft Excel Function Reference," version 4.0, 279, 431-432
"Microsoft Excel Function Reference," version 3.0, 156, 234-235
Additional query words:
3.0 4
Keywords :
Version :
Platform :
Issue type :
Last Reviewed: March 22, 1999