Sub Chronometer_Tick
' pm = PeriodBetweenWithMilliseconds(StartTime, DateTime.Now)
' Label1.Text = FN(pm.p.Hours) & ":" & FN(pm.p.Minutes) & ":" & FN(pm.p.Seconds) & "." & _
' NumberFormat(pm.ms, 3, 0)
Label1.Text = getConvertTickToHHmmsszs(DateTime.Now - StartTime)
End Sub
Sub getConvertTickToHHmmsszs(time As Long) As String
Dim vorzeichen As String=""
Dim h,m,s,zs As Int
Dim t As Long=Abs(time)
If time < 0 Then vorzeichen="-"
zs = t Mod 1000
s = (t/1000) Mod 60
m = (t/60000) Mod 60
h = (t/3600000) Mod 24
Return vorzeichen & NumberFormat(h,2,0) & ":" & NumberFormat(m,2,0) & ":" & NumberFormat(s,2,0) & "." & NumberFormat2(zs,3,0,0,False)
End Sub