> intYear=2004
intMonth=06
I want to convert intYear & intMonth to 06/01/2004 thru 06/30/2004. Is
there a way? And if it's Feb the endining day will be 28 if its Jan it will
be 31 etc.
Dim intYear As Long
Dim intMonth As Long
intYear = 2004
intMonth = 6
Debug.Print "Date range for the month is " & _
DateSerial(intYear, intMonth, 1) & " thru " & _
DateSerial(intYear, 1 + intMonth, 0)
Note that I used the 0th day of the next month to get the last day of
the specified month.
Rick - MVP