How I can create timer in classic asp?

How can i create a 20 mins.countdown timer in VB 6.0?

  • how can i create a 20 minutes countdown timer in VB 6.0 with a Start,Pause and Stop command..please help..thanks

  • Answer:

    this is a 5 second timer. You will have to change things around Dim x As Integer Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick x = x - 1 Label2.Text = Int(x / 10) & "." & x Mod 10 If x < 1 Then Timer1.Enabled = False MsgBox("BOOM") End If End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If Timer1.Enabled = False Then Timer1.Enabled = True Button1.Text = "Stop" Else Timer1.Enabled = True Timer1.Enabled = False Button1.Text = "Start" End If If x = 7 Then Timer1.Stop() MsgBox("good job, 007") End If End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click If Timer1.Enabled = False Then x = 40 End If Label2.Text = "4.0" End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load x = 50 End Sub End Class

Jhanine at Yahoo! Answers Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.