It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

News

Log In Sponsors
Partner Sites

Timer - Newbie!



Hey people I have been asked to do a counter/timer with two command buttons one for counting up and one for counting down also a menu with different time intervals. As far as I know I have done the menu bit but stuck on the timer code.

I have two command buttons and I have set a varible called blnCountDown as a boolean. In cmd_CountUp i have set the variable to False and in cmd_CountDown i have set the variable to true.
This is the code for me timer:

Private Sub tmrTimerOne_Timer()
Total = txtDisplay.Text
If blnCountDown = True Then
Total = Total - 1
Else
Total = Total + 1 'but on this line i have an error wen i run it and it sats mismatch...can u help!
End If
txtDisplay.Text = Total

End Sub

Any help would be gr8 iam kinda new to this!

Click here to read the whole forum topic