Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
I am using
=MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. =YEAR(H6) works fine. Many Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
Hi
don't format the cell as MM. just format the cell as 'Number' or 'General' -- Regards Frank Kabel Frankfurt, Germany Rich wrote: I am using =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. =YEAR(H6) works fine. Many Thanks |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
try this
Format Cell Custom 0 ----- Rich wrote: ---- I am using =MONTH(H6 and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why =YEAR(H6) works fine Many Thank |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
On Sun, 16 May 2004 10:55:31 -0700, "Rich"
wrote: I am using =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. =YEAR(H6) works fine. Many Thanks =MONTH(H6) returns a number in the range of 1-12. When you format the cell as 'mm', Excel thinks you mean a date. Excel stores dates as serial numbers where 1 = 1 jan 1900 (or 1904). So when Excel sees a date that is in the range of 1-12, it interprets that as a date in the range 1 Jan to 12 Jan 1900 (or 1904). So that function will always return a 1 since the number represents the month of January. It is only serendipity that YEAR(H6) appears to work. It is probably really returning a year in the early 1900's. Suggestion: format the cell as General. --ron |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
Hi,
mm is minutes, format to mmm for Month. Matt -----Original Message----- I am using =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. =YEAR(H6) works fine. Many Thanks . |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
"Ron Rosenfeld" wrote in message ... On Sun, 16 May 2004 10:55:31 -0700, "Rich" wrote: It is only serendipity that YEAR(H6) appears to work. I wouldn't call it serendipitous if that was what you were looking for, fortuitous maybe, but not serendipitous. |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
On Sun, 16 May 2004 20:56:46 +0100, "Bob Phillips"
wrote: "Ron Rosenfeld" wrote in message .. . On Sun, 16 May 2004 10:55:31 -0700, "Rich" wrote: It is only serendipity that YEAR(H6) appears to work. I wouldn't call it serendipitous if that was what you were looking for, fortuitous maybe, but not serendipitous. You can call it either. The first definition of serendipitous includes fortuitous. (Random House Webster's Unabridged Dictionary V3.0) serendipitous, adj. 1. come upon or found by accident; fortuitous: serendipitous scientific discoveries. --ron |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
It may include fortuitous, but if it is fortuitously finding what you
expected, where is the happy accident in that? -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Ron Rosenfeld" wrote in message ... On Sun, 16 May 2004 20:56:46 +0100, "Bob Phillips" wrote: "Ron Rosenfeld" wrote in message .. . On Sun, 16 May 2004 10:55:31 -0700, "Rich" wrote: It is only serendipity that YEAR(H6) appears to work. I wouldn't call it serendipitous if that was what you were looking for, fortuitous maybe, but not serendipitous. You can call it either. The first definition of serendipitous includes fortuitous. (Random House Webster's Unabridged Dictionary V3.0) serendipitous, adj. 1. come upon or found by accident; fortuitous: serendipitous scientific discoveries. --ron |
#9
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
"Rich" skrev i melding
... =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. =YEAR(H6) works fine. It's not very obvious what you expect to see. MONTH returns the month /number/. YEAR returns the year number -which usually is just fine. If you want to see "feb" or "oct" then either =TEXT(H6,"mmm") for returning the real text, or =H6 format cell as "mmm", for keeping the date and just display the text. =MONTH(H6) formatted as mmm will always return jan btw, so son't do that. HTH. Best wishes Harald |
#10
Posted to microsoft.public.excel.programming
|
|||
|
|||
Re2: Month
"Rich" skrev i melding
... I am using =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. Sent too quick, sorry. Completed =MONTH(H6) formatted as mmm will always return jan btw, so son't do that. The formula will return month number as stated, and dates 1 to 12 is January 1st to january 12th 1900. Which are all in january, month 01. |
#11
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
Could do
=MONTH(H6) * 29 then format as mm It's rough, but how often does the calendar change? -- Rob van Gelder - http://www.vangelder.co.nz/excel "Harald Staff" wrote in message ... "Rich" skrev i melding ... I am using =MONTH(H6) and have the format of the cell set to mm the value is stuck at 01 and I cannot understand why. Sent too quick, sorry. Completed =MONTH(H6) formatted as mmm will always return jan btw, so son't do that. The formula will return month number as stated, and dates 1 to 12 is January 1st to january 12th 1900. Which are all in january, month 01. |
#12
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
On Mon, 17 May 2004 07:59:48 +0100, "Bob Phillips"
wrote: It may include fortuitous, but if it is fortuitously finding what you expected, where is the happy accident in that? OIC your point now. Since he was formatting the MONTH result as a date, I assumed (I know my assumption may be incorrect), that he was also formatting the YEAR as a date. --ron |
#13
Posted to microsoft.public.excel.programming
|
|||
|
|||
Month
Ron,
I was just picking up on the word, Serendipity is one of my favourites. Regards Bob "Ron Rosenfeld" wrote in message ... On Mon, 17 May 2004 07:59:48 +0100, "Bob Phillips" wrote: It may include fortuitous, but if it is fortuitously finding what you expected, where is the happy accident in that? OIC your point now. Since he was formatting the MONTH result as a date, I assumed (I know my assumption may be incorrect), that he was also formatting the YEAR as a date. --ron |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
excel to make the days cary over month to month automaticly | New Users to Excel | |||
Excel 2003 month to month data change grid | Excel Discussion (Misc queries) | |||
Converting Month Number to Month Text Abbreviation | Excel Worksheet Functions | |||
When using MONTH function on Blank Cell!! Returns Month=Jan! | Excel Discussion (Misc queries) | |||
transfer cell $ amount to other sheet month-to-month without overc | Excel Discussion (Misc queries) |