
vb怎么实现模拟鼠标点击延迟
PrivateSubCommand1_Click()SetCursorPos389,311mouse_eventMOUSEEVENTF_LEFTDOWN,0,0,0,0'...
Private Sub Command1_Click()
SetCursorPos 389, 311
mouse_event MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0 '鼠标按下左键
SetCursorPos 389, 311
mouse_event MOUSEEVENTF_LEFTUP, 0, 0, 0, 0 '鼠标释放左键
SetCursorPos 1126, 417
mouse_event MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0 '鼠标按下左键
SetCursorPos 1126, 417
mouse_event MOUSEEVENTF_LEFTUP, 0, 0, 0, 0 '鼠标释放左键
End Sub 展开
SetCursorPos 389, 311
mouse_event MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0 '鼠标按下左键
SetCursorPos 389, 311
mouse_event MOUSEEVENTF_LEFTUP, 0, 0, 0, 0 '鼠标释放左键
SetCursorPos 1126, 417
mouse_event MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0 '鼠标按下左键
SetCursorPos 1126, 417
mouse_event MOUSEEVENTF_LEFTUP, 0, 0, 0, 0 '鼠标释放左键
End Sub 展开
展开全部
延迟用sleep函数,vb的api浏览器里面有声明的,去copy过来就行.
sleep 1000就是延迟1000毫秒,你可以随机一个值去sleep,这样显得真实
sleep 1000就是延迟1000毫秒,你可以随机一个值去sleep,这样显得真实
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询