View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
NickHK NickHK is offline
external usenet poster
 
Posts: 4,391
Default last day of the month

This is weird:
In Bob's reply I see "var2 = dateserial(2005,var1,0)" and was going to
correct it.
But then noticed in JT's quoted reply to Bob "var2 =
dateserial(2005,var+1,0)", correct.

Is it just my OE reader or anyone else seeing the same ?

NickHK

"Bob Phillips" wrote in message
...
var2 = dateserial(2005,var1,0)

--
HTH

Bob Phillips

"JT" wrote in message
...
Is there a way to automatically fill a variable with the last day of the
month based on the month in another variable?

For example, if var1 = 9, is there a way to program var2 = 9/30/2005 or

if
var1 = 8, then var2= 8/31/2005

Thanks.......
--
JT