Results 1 to 3 of 3

Thread: go to a certain date and work backwards

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 2001
    Location
    London
    Posts
    101

    go to a certain date and work backwards

    Hi there,
    I need to create a procedure which will track back from the date entered in a textbox to the previous 6 April (end of tax year). From there I want to take the tax limit for that year and the previous 2 tax years. Any ideas on how I would do this?

    i.e.
    User enters 8/November/99, therefore go back to 6/April/99, put the tax limit of that year into text1, the tax limit of '98 into text2 and the tax limit of 97 into text3. I have the tax limits stored in a db.

  2. #2
    Member piyushpatel's Avatar
    Join Date
    Dec 2001
    Location
    A'bad,India
    Posts
    55
    Hey pobuckley
    excuse me this is not the project.
    So u cant put this in project's forum
    put in general VB questions forum i assured u will get
    answer in 2 hours.
    hey pobuckley dont mind but u shoud follow rules.

    R u intrested in cricket ? What u think england can win here in india.I guess another whitewash follows ur way.
    Dont mind this also

  3. #3
    Si_the_geek
    Guest
    This wil set year_start to the start of the tax year (assuming my_date is your input date)
    VB Code:
    1. year_start = "6/4/" & Year(my_date)
    2. If CDate(year_start) > CDate(my_date) Then
    3.   year_start = DateAdd("yyyy", -1, year_start)
    4. End If

    PS: us Brit's dont like cricket... we know we just can't play it!

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