P
Philosophaie
Looking to have a timer set off an alarm at 15 minute intervals as in Visual
Basic.net
Dim WithEvernts Timer1 as Timer
Dim TimeRemaining as Integer ==15*60
Private Sub Worksheet_Open
Timer1.Interval=5000
Timer1 Enabled=True
Timer1.Start() ' this does not work in Excel but does in VB.net
end sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Timer1.Tick
TimeRemaining=TimeRemaining-5
If timeRemaing =0 then
....
Enact Alarm
....
TimeRemaining=15*60
End if
End Sub
Basic.net
Dim WithEvernts Timer1 as Timer
Dim TimeRemaining as Integer ==15*60
Private Sub Worksheet_Open
Timer1.Interval=5000
Timer1 Enabled=True
Timer1.Start() ' this does not work in Excel but does in VB.net
end sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Timer1.Tick
TimeRemaining=TimeRemaining-5
If timeRemaing =0 then
....
Enact Alarm
....
TimeRemaining=15*60
End if
End Sub