Watchdog timer issues
In message of Sat, 29 Oct 2016 17:50:33 in
microsoft.public.excel.programming, GS writes
Gary,
Thanks for your input.
Walter,
Try...
Private Const vKillET = "00:00:30"
That is effectively what I do in
Private Const killduration As String = "00:00:30"
I don't do Magyar. ;)
I feel I should be able to do
Private Const vKillET as date = sommething.
..and in your function...
killtime = TimeValue(Now) + TimeValue(vKill_ET)
'returns time in hh:mm:ss AM/PM
I do that partially with
killtime = now + TimeValue(killduration)
Why would you "cast" now?
?typename(now)
Date
?typename(timevalue(now))
Date
Also, in your function you might want to def a var to hold the boolean
value used in your If..Then block. It can be set True as a default
unless a condition toggles it false...
Dim bMyVar As Boolean
bMyVar = True '//assume success
'//some code that preserves or toggles bMyVar
If Not bMyVar Then
newie:
...
I must concede I am overloading killtime as both a value and a flag.
Slightly insanitary. ;)
How do I turn green cell north west corners into text?
--
Walter Briscoe
|