View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Lars-Åke Aspelin[_4_] Lars-Åke Aspelin[_4_] is offline
external usenet poster
 
Posts: 83
Default Convert Week number into Month

On Thu, 27 May 2010 17:00:01 -0700, KT
wrote:

I have a worksheet with values for year and week number. I need to convert
these to the descriptive month name. Some weeks cross month ends, but this
is okay, I just need a single value for each record. It could be the month
of the first day of each week number. Using Excel 2003.

Thanks for your ideas.


If your year is in cell A1 and you week number is in cell B2, try the
following formula:

=MONTH(DATE(A1,1,MATCH(TRUE,WEEKNUM(DATE(A1,1,ROW( A1:A366)),2)=B1,0)))

Note: This is an array formula that should be confirmed by
CTRL+SHIFT+ENTER rather than just ENTER.

Note 2: WEEKNUM does not support European standard for week number,
see
http://office.microsoft.com/en-us/ex...093371033.aspx

If you use the European standard for week numbers, you have to put
some more logic into the formula to handle the case, like this year,
where the first few days of the year is not week number 1.
In Europe January 1-3 of 2010 is week number 53.

Hope this helps / Lars-Åke