calculate the contract end remaining days

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • musab hosawy
    New Member
    • Feb 2012
    • 2

    calculate the contract end remaining days

    i need to calculate the days left for a contract to end

    i have a table contain the (start_cont) and from the query

    i calculated the (end_cont)

    end_cont=( DateAdd("d";-1;DateAdd("yyyy ";3;[tbcontract]!
    [start_day])).

    now i whant to calculate the days left before the contract

    end (ex= 2 days 3 monthe 2 years)in this format

    pleas hlp accesss 2007
  • ADezii
    Recognized Expert Expert
    • Apr 2006
    • 8834

    #2
    It would look something like:
    Code:
    Days_Left:DateDiff("d", [start_day], DateAdd("d", -1, DateAdd("yyyy", 3, [start_day])))

    Comment

    • musab hosawy
      New Member
      • Feb 2012
      • 2

      #3
      will i use this DateDiff("m";Da te();date_end )& "monthe"

      but its only give me the monthe i whant the days ,monthe, years

      i need to Calculate difference between 2 dates in years months and remaining days

      Comment

      • ADezii
        Recognized Expert Expert
        • Apr 2006
        • 8834

        #4
        You would then need a Custom Function to perform the job.

        Comment

        Working...