anonymous
2009-01-29 16:11:51 UTC
1Lable >> I want the lable to show my countdown timer
1Timer
1Button
Ok i got a timer in this format Label2.Text = m + ":" + s
But i still can get the timer to start from 3 mins and count down to 0
Here is my full code
Public Class Form1
Dim m As String
Dim s As String
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
s = s - 1
If s = 60 Then
s = 0
m = m + 1
End If
Label2.Text = m + ":" + s
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Timer1.Interval = 1000
Timer1.Enabled = True
End Sub
End Class
What i want is to start the timer at 3:00 and have it countdown to 0:00
Please give answer in detail as im kinda new in vb