Results 1 to 2 of 2
  1. #1
    5 Star Lounger
    Join Date
    Mar 2001
    Location
    New York, NY
    Posts
    922
    Thanks
    2
    Thanked 12 Times in 11 Posts

    Date Value (Word XP)

    I'm using the Date/Time Picker to allow the user to enter the date of end of fiscal year. Knowing the FYE date, I want to pre-fill the value of a subsequent Date/Time Picker with the date of the beginning of the fiscal year. That means the 1st day of the next month, a year earlier.

    The FYE value is dtFYE.Value. How would I set the value of dtFYB based on that?

    Thanks,
    Richard Barrett

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date Value (Word XP)

    Try this:

    Private Sub dtFYE_Change()
    Me.dtFYB.Value = DateAdd("yyyy", -1, Me.dtFYE.Value + 1)
    End Sub

Posting Permissions

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