• Thx mr Eriksson for your quickley reaction
    15 years ago i create 1 app in Delphi with foxpro as database
    now i wil create this in VB.net and Sql Server
    the prog is for employment registration with barcode
    by scanning
    the program must look or there is already a record with this date and Id,
    Employe can leave company and comeback later on the day

    now i explain the follow steps by registry
    1] employe  146 scan at 16/11/2017 06:33:15
    2] searching record with id 146 and date 16/11/2017
     if  found look to scanin
       if scanin IS NULL
         scanin = registrytime
       Else
        compare scanin  and registrytime
         if different between registry time and scanin > 3 minutes ---( security agains double registry)
           look at scanout
          If scanout IS NULL 
           scanout = registrytime
         Else
         compare scanout and registrytime
          if different between registry time and scanout > 5 minutes ---( security agains double registry)
          insert new record
    Else -- record not found
       insert new record
    -----------------------
    The next step = calculate the working hours
    I hope you understand the logic.
    Thx almost mr Eriksson

    Ken er nog niet veel van, maar leer het wel
    Do not know much about it yet, but learn