|
- Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
- Private Declare PtrSafe Function GetKeyState Lib "user32" (ByVal nVirtKey As Long) As Long
- Const VK_NUMLOCK = &H90
- Sub SetMouseClickLock()
- Dim shellApp As Object
- Dim state As Long
- Set shellApp = CreateObject("Shell.Application")
- shellApp.ShellExecute "control.exe", "mouse", "", "open", 1
- Sleep 2000
- SendKeys "^t", True
- Sleep 1000
- SendKeys "%{F4}", True
- state = GetKeyState(VK_NUMLOCK)
- If (state And 1) = 0 Then SendKeys "{NUMLOCK}" '
- End Sub
复制代码 看起来论坛二次编辑代码有点问题,自己在这个基础上进行扩展开发吧 |
评分
-
3
查看全部评分
-
|