or... just by extending the formula that I used the first time like this:
Formula:
=IF(ISNUMBER(A2),IF(AND(A2>=DATE(2010,7,1),A2<=DATE(2010,12,31)),2011,YEAR(A2)),IF(AND(--LEFT(A2,4)=2010,--MID(SUBSTITUTE("-"&$A2,"-",REPT(" ",125)),125*COLUMNS($A:B),125)>=7),2011,LEFT(A2,4)))
will do it.
It would also be possible to adapt Alkey's tidier solution, but it would depend on what digits can appear in the last group in A 1 to A3. Is 405 or 656 (ie anything where the first two digits exceed the number of days in a month) possible?
Bookmarks