怎样用VB做一个计时器?

来源:百度知道 编辑:UC知道 时间:2024/06/07 22:26:03

画一个command 一个timer

Private Sub Command1_Click()
Timer1.Enabled = True
End Sub

Private Sub Form_Load()
Timer1.Enabled = False
Timer1.Interval = 1000
Command1.Caption = "开始计时"
End Sub

Private Sub Timer1_Timer()
Command1.Caption = Val(Command1.Caption) + 1
End Sub

一楼的可以用。。。