Results 1 to 2 of 2

Thread: [Resolved]Date variable

  1. #1

    Thread Starter
    Hyperactive Member yousufkhan's Avatar
    Join Date
    Jan 2002
    Location
    India
    Posts
    492

    Resolved [Resolved]Date variable

    I am having a date variable strdate as date
    i wanted to capture one month advance date from the present date in the
    strdate variable

    example presented date : 23/11/2004
    strdate should be : 23/12/2004
    how can i do this
    Last edited by yousufkhan; Feb 3rd, 2005 at 04:06 AM. Reason: [Resolved]

  2. #2
    Frenzied Member trisuglow's Avatar
    Join Date
    Jan 2002
    Location
    Horsham, Sussex, UK
    Posts
    1,536

    Re: Date variable

    Is this good enough? You may not be happy with the way it deals with Jan 31st...


    VB Code:
    1. Private Sub Command2_Click()
    2.   Debug.Print DateAdd("m", 1, CDate("31/1/05"))
    3.   Debug.Print DateAdd("m", 1, CDate("15/1/05"))
    4. End Sub
    This world is not my home. I'm just passing through.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width