Hi there, I've been browsing the groups but I haven't seen this posted before.
I'd like to have a separate countdown timer for each record on a continous form.
The below code works fine as a timer but it displays the same for each record. Is it possible to have them running separately?
Dim lng As Long, sec As Long
lng = DateDiff("s", Nz(Me!txtTime, Date), Now)
If 60 - (lng Mod 60) = 60 Then
sec = 0
lng = lng - 60
Else
sec = 60 - (lng Mod 60)
End If
lng = 44 - Fix(lng / 60)
If lng < 1 Then Me!txtCountDown.ForeColor = 255
Me!txtCountDown = Format(lng, "00") & ":" & Format(sec, "00")
Thanks!
Michael
I'd like to have a separate countdown timer for each record on a continous form.
The below code works fine as a timer but it displays the same for each record. Is it possible to have them running separately?
Dim lng As Long, sec As Long
lng = DateDiff("s", Nz(Me!txtTime, Date), Now)
If 60 - (lng Mod 60) = 60 Then
sec = 0
lng = lng - 60
Else
sec = 60 - (lng Mod 60)
End If
lng = 44 - Fix(lng / 60)
If lng < 1 Then Me!txtCountDown.ForeColor = 255
Me!txtCountDown = Format(lng, "00") & ":" & Format(sec, "00")
Thanks!
Michael