View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
John Smith[_15_] John Smith[_15_] is offline
external usenet poster
 
Posts: 2
Default Incrementing times and dates

well take a better look: these are not strings

they are converted from strings to dates
just because of the Dim declaration

D is supposed to be a date, so D = "..."
makes VBA try to convert the "..." to the date type.

But you may use D = CDate("...") if you want to much more understand the
key of my code. (this CDAte is auto-added by VBA by default)


Many thanks,

I have improved my code by using your method - it saved me a lot of time and
stress.

Cheers

JS