Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
I'm a lefty, and sometimes you need to be able to switch which button your mouse settings use (for example, when you use RDP in with a Macbook into a Windows 7 machine) to use right-handed norms on OS' which use "right" and "left" rather than "primary" and "secondary." This is JScript, not JavaScript.
obsS=WScript.CreateObject("WScript.Shell")
obsS.Run("control mouse", 5)
WScript.sleep(1000)
obsS.AppActivate("Mouse")
WScript.Sleep(300)
obsS.Sendkeys(" ")
WScript.Sleep(123)
obsS.SendkEys("{Enter}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment