lucarello wrote:hallo, is there a way to back or lay when timer in D2 goes under zero seconds?
the instruction:
"If Range("Sheet1!D2").Value < TimeValue("00:00:29") Then ... "
works only until 0:00:00, but often I need to bet after some other seconds
tnx who helps
Try this:
Put the following formula in a cell say W1
=IF(LEFT(D2)<>"-",(HOUR(D2)*3600)+(MINUTE(D2)*60)+SECOND(D2),-((HOUR(SUBSTITUTE(D2,"-",""))*3600)+(MINUTE(SUBSTITUTE(D2,"-",""))*60)+SECOND(SUBSTITUTE(D2,"-",""))))
What the formula does is that it counts down to the scheduled off, and the figure becomes negative when gone past the scheduled off. You can then amend your code to read:
"If Range("W1").Value < 0 Then ... "
HTH