三九宝宝网宝宝教育教学论文

用vb程序语言设计一个秒表计时器包括开始停止和调试

12月24日 编辑 39baobao.com

Private x As Double

Private Sub Form_Load()

Timer1.Interval = 100

Timer1.Enabled = False

End Sub

Private Sub Command1_Click()

Timer1.Enabled = True

End Sub

Private Sub Command2_Click()

Timer1.Enabled = False

End Sub

Private Sub Command3_Click()

Timer1.Enabled = False

x = 0

End Sub

Private Sub Timer1_Timer()

x = Round((x + 0.1), 1)

If x < 1 Then Text1 = "0" & x Else Text1 = x

End Sub

推荐阅读
图文推荐