hey
i have a form with login in and log out options
now i added another field in the Database with the name Logtotal = (time in time out)
only when i log out and then log in i can see the log out time.
how do i calculate between those two field ?
after i log in ofcorse
this is the code that loads from the DB
Code:Set RS = CN.Execute("SELECT * FROM Logs ORDER BY LogId") While Not RS.EOF Set Itm = FrmSecurityreport.LsVw.ListItems.Add(, , RS!LogId, , "report") Itm.Tag = RS!LogId Itm.bold = True Itm.SubItems(1) = RS!LogDate Itm.SubItems(2) = RS!LogDay Itm.SubItems(3) = RS!LogName Itm.SubItems(4) = RS!LogIn If Not IsNull(RS!logout) Then Itm.SubItems(5) = RS!logout End If If Not IsNull(RS!LogTotal) Then Itm.SubItems(6) = RS!LogTotal End If RS.MoveNext DoEvents Wend
tnx for the help




Reply With Quote