View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
voodooJoe voodooJoe is offline
external usenet poster
 
Posts: 43
Default Subtract 1 year from todays date

using a formula: =EDATE(TODAY(),-12)
using VBA: dateadd("yyyy",-1,date)

cheers - voodooJoe

"Nigel" wrote in message
...
I have looked and I know it must be eady but I want to subtract 1 year from
todays date in code, so I tried date-1 year but to no avail, I can use
date-365 but I would like it to automatically take into account leap years

Thanks