Apologies for A1>0 above. It should be if cell value [A1] > 00:00:15 ( ie 15 seconds). How to write a code so that a macro called "Mega" runs only once if cell value A1 > 00:00:15 ( time ), EVEN THOUGH the cell value (A1)remains increasing after that. The macro called "Mega" will also reset the value of cell A1 to zero which will start increasing with time but the macro ( Mega ) should not run for the second time. Please see the attached file. Once the macro "Mega" runs once and resets the cell A1 will start increasing with time but next time when it crosses 15 seconds, it should not trigger by itself( ie by the code which we write( ideally a simple code like
Private Sub Worksheet_Calculate()
If [A1] > Time(0,0,15) Then
Mega
End If
End Sub
......will run it , but then there is nothing to stop it from running again. What can we do to change this code so that Mega may run only once ?
Bookmarks