hey. i have made a timer to countdown in visual basics 6.0 , but i need it stop the game i made when the countdown is finished. This is Part of an assignment .
P.S. I am not a computer guy.
VB timer countdown. plz help! (homework assignment)when the timer has finished countdown how will you stop the preview bu
Page 1 of 1
6 Replies - 12023 Views - Last Post: 05 June 2008 - 12:08 AM
Replies To: VB timer countdown. plz help! (homework assignment)
#2
Re: VB timer countdown. plz help! (homework assignment)
Posted 25 May 2006 - 01:04 AM
What does the timer do?
Is it like a Countdown Timer which shuts or gives an alarm on ZERO?
Keep a global variable and keep incrementing or decrementing it in the Timer Subroutine and disable the timer when it reaches ZERO.
It should work out to be something like this:
Since you said you're not a computer guy, I'm not exactly sure whether my post will be understood by you (global variables etc.).
If you have any queries, feel free to post again.
Is it like a Countdown Timer which shuts or gives an alarm on ZERO?
Keep a global variable and keep incrementing or decrementing it in the Timer Subroutine and disable the timer when it reaches ZERO.
It should work out to be something like this:
Private Sub Timer1_Timer() g_count = g_count - 1 ' Assuming g_count is a global variable if g_count = 0 then timer1.enabled = false End Sub
Since you said you're not a computer guy, I'm not exactly sure whether my post will be understood by you (global variables etc.).
If you have any queries, feel free to post again.
#3
Re: VB timer countdown. plz help! (homework assignment)
Posted 25 May 2006 - 01:11 AM
One more thing...have you made an attempt to solve this assignment?
If so then please post whatever you have written as we can then correct you and tell you where you went wrong.
If so then please post whatever you have written as we can then correct you and tell you where you went wrong.
#4
Re: VB timer countdown. plz help! (homework assignment)
Posted 25 May 2006 - 03:06 PM
VB is probably the best language for beginners in computers/programming as it is mostly drag and drop and the graphics are taken care of 
It is likely a slimple logic error, which could be resolved once the code is posted.
It is likely a slimple logic error, which could be resolved once the code is posted.
#5
Re: VB timer countdown. plz help! (homework assignment)
Posted 25 May 2006 - 09:58 PM
Quote
VB is probably the best language for beginners in computers/programming as it is mostly drag and drop and the graphics are taken care of
I'd say the same thing...only without the word 'probably'
#6
Re: VB timer countdown. plz help! (homework assignment)
Posted 04 June 2008 - 08:07 PM
born2c0de, on 25 May, 2006 - 01:04 AM, said:
What does the timer do?
Is it like a Countdown Timer which shuts or gives an alarm on ZERO?
Keep a global variable and keep incrementing or decrementing it in the Timer Subroutine and disable the timer when it reaches ZERO.
It should work out to be something like this:
Since you said you're not a computer guy, I'm not exactly sure whether my post will be understood by you (global variables etc.).
If you have any queries, feel free to post again.
Is it like a Countdown Timer which shuts or gives an alarm on ZERO?
Keep a global variable and keep incrementing or decrementing it in the Timer Subroutine and disable the timer when it reaches ZERO.
It should work out to be something like this:
Private Sub Timer1_Timer() g_count = g_count - 1 ' Assuming g_count is a global variable if g_count = 0 then timer1.enabled = false End Sub
Since you said you're not a computer guy, I'm not exactly sure whether my post will be understood by you (global variables etc.).
If you have any queries, feel free to post again.
This code doesn't work for me, it does it once then stops. If I make my variable = 30 then it will subtract once, when I want it to count down to 0
#7
Re: VB timer countdown. plz help! (homework assignment)
Posted 05 June 2008 - 12:08 AM
Could you post the code you have?
Your problem will be solved much more quickly if we can see the code that is causing problems.
Your problem will be solved much more quickly if we can see the code that is causing problems.
Page 1 of 1
|
|

New Topic/Question
This topic is locked




MultiQuote




|