|
-
May 24th, 2012, 02:59 PM
#1
A timer in Hrs, Mins + Secs
This is what I have so far.
Code:
Private Sub Label1_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label1.Click
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
Label1.Text = Label1.Text + 0.01
End Sub
Private Sub Label2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label2.Click
End Sub
Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
If Label1.Text = 60 Then Label2.Text = Label2.Text + 1 And Label1.Text = 0
End Sub
Private Sub Label3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label3.Click
End Sub
Private Sub Timer3_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer3.Tick
If Label2.Text = 60 Then Label3.Text = Label3.Text + 1 And Label2.Text = 0
End Sub
End Class
The first part (Label 1 + Timer 1) works fine and it counts seconds but I want it to count minutes and hours too. I am quite new to VB so excuse any obvious mistakes. Help is much appreciated 
-Skrill
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|