Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
var setControlPanel = function(cmd, title, keystrokes){
var WshShell = WScript.CreateObject("WScript.Shell");
WshShell.Run(cmd);
do {
WScript.Sleep(100);
} while(!WshShell.AppActivate(title));
WshShell.SendKeys(keystrokes);
};
setControlPanel("control main.cpl",
"マウスのプロパティ",
"{" + WScript.Arguments.item(0) +
"}^{TAB}{HOME}{DOWN " +
WScript.Arguments.item(1) +
"}{ENTER}"
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment