Leave days calculations

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • cknkomo
    New Member
    • Feb 2007
    • 1

    #1

    Leave days calculations

    Hie

    I am learning VB and I have a table with the following fields:

    - EmployeeNo
    - Date of Engagement
    - From Date
    - End Date
    - Days Acrued
    - Days taken
    - Balance

    What I want is to calculate DAYS ACRUED by finding the difference between DATE OF ENGAGEMENT and DATE NOW

    Secondly DAYS TAKEN = END DATE minus FROM DATE

    then BALANCE = DAYS ACRUED - DAYS TAKEN

    Please held me how to write the code
  • willakawill
    Top Contributor
    • Oct 2006
    • 1646

    #2
    Hi. Perhaps you would like to check out the DateDiff() function

    Comment

    Working...