Thread: if function
View Single Post
  #5   Report Post  
swatsp0p
 
Posts: n/a
Default


Then try this...assumes dates begin in A2, paste in B2, copy down 1k
rows:

=IF(WEEKNUM(A2,1)52,"Qtr: 4 Week: 14","Qtr
"&IF(MOD(WEEKNUM(A2,1),13)=0,WEEKNUM(A2,1)/13,INT(WEEKNUM(A2,1)/13)+1)&"
Week: "&IF(MOD(WEEKNUM(A2,1),13)=0,13,MOD(WEEKNUM(A2,1), 13)))

Things get really ugly late in December, as often there are more that
13 weeks in the 4th Qtr. This attempts to address that by making a
week 14 in Qtr 4.

I hope this meets your needs.

note: you need to have the Analysis ToolPak Add-In installed for the
"WEEKNUM" function to work.

Bruce


--
swatsp0p


------------------------------------------------------------------------
swatsp0p's Profile: http://www.excelforum.com/member.php...o&userid=15101
View this thread: http://www.excelforum.com/showthread...hreadid=468810