vb.net System.Timers.Timer怎么用?
答案:2 悬赏:40 手机版
解决时间 2021-11-26 20:08
- 提问者网友:贪了杯
- 2021-11-25 22:44
vb.net System.Timers.Timer怎么用?
最佳答案
- 五星知识达人网友:低血压的长颈鹿
- 2021-11-25 22:53
Dim TimerMove As System.Timers.Timer
TimerMove = New System.Timers.Timer
With TimerMove
AddHandler TimerMove.Tick, AddressOf TimerMove_Tick
TimerMove.Interval = 1000
TimerMove.Start()
End With
Private Sub TimerMove_Tick(ByVal sender As Object, ByVal e As EventArgs)
Label2.Left = Label2.Left - 20
If Label2.Left = -200 Then
Label2.Left = 1000
End If
End Sub
TimerMove = New System.Timers.Timer
With TimerMove
AddHandler TimerMove.Tick, AddressOf TimerMove_Tick
TimerMove.Interval = 1000
TimerMove.Start()
End With
Private Sub TimerMove_Tick(ByVal sender As Object, ByVal e As EventArgs)
Label2.Left = Label2.Left - 20
If Label2.Left = -200 Then
Label2.Left = 1000
End If
End Sub
全部回答
- 1楼网友:逐風
- 2021-11-25 23:44
http://blog.csdn.net/xiaocuner/archive/2009/01/16/3793557.aspx
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
推荐资讯