View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Christopher Naveen[_2_] Christopher Naveen[_2_] is offline
external usenet poster
 
Posts: 58
Default Year & Month format

Hi,

I have col which contains year & month. Now i want to pull the values which
is less than or equal to current month.

A
2006-08
2008-04
2007-11
2008-01
2007-11

I tried with this formula but it is not working. Can any one help me?

=IF(year(a2)&"-"&MONTH(A2)<=year(TODAY()&"-"&month(today()),MONTH(TODAY())&"-"&YEAR(TODAY()),"")


- Christ