- 分享
- 0
- 人气
- 0
- 主题
- 57
- 帖子
- 1160
- UID
- 41984
- 积分
- 10187
- 阅读权限
- 25
- 注册时间
- 2006-8-23
- 最后登录
- 2024-6-21
- 在线时间
- 12198 小时
|
Private Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)
Private Const MOUSELEFTDOWN = &H2
Private Const MOUSELEFTUP = &H4
Private Sub Form_Load()
Label1.Caption = HScroll1.Value
Timer1.Enabled = False
Timer1.Interval = HScroll1.Value
End Sub
Private Sub HScroll1_Change()
Label1.Caption = HScroll1.Value
Timer1.Interval = HScroll1.Value
End Sub
Private Sub HScroll1_Scroll()
Label1.Caption = HScroll1.Value
Timer1.Interval = HScroll1.Value
End Sub
Private Sub cmdStart_Click()
Timer1.Enabled = True
End Sub
Private Sub cmdStop_Click()
Timer1.Enabled = False
End Sub
Private Sub Timer1_Timer()
mouse_event MOUSELEFTDOWN, 0, 0, 0, 0 'left button goes down
mouse_event MOUSELEFTUP, 0, 0, 0, 0 'left button comes up
End Sub |
|