Right... I didn't mean to imply you needed that switch all the time, where it comes in super-handy is if you need to run a command window (cmd) ELEVATED. If you don't use this switch, you get an empty powershell window AND command window (and a UAC prompt). For example, you can call powershell, have it in turn call a DOS-type command or batch file in an elevated command shell. I use this trick to control a Windows service, so that I get no output except for a UAC prompt (and no flash of any windows). Normally, RunCommand with "Hide" is all you need.jsmorley wrote:In digging a bit deeper, I'm not convinced the -NonInteractive parameter has anything to do with whether the console is displayed. It seems to have to do with whether or not an interactive "prompt" is displayed. In any case, with RunCommand I don't think you ever need it.
To redirect this thread back to the original topic... The original poster's problem is that he needs to call the Win32 SystemParametersInfo API to change the mouse sensitivity immediately. Just changing the registry has no effect until logoff/logon, so you need to do both. I redirected the OP to a link where he can get a Powershell script that will create a function called Set-MouseSpeed. Using this, along with a RunCommand plugin, will allow him to run a Powershell command that will provide him the ability to pass a parameter to vary the sensitivity, which was his request.
The RunCommand command would be something like
...where the script is located in the @Resources folder and the [&MeasureSpeed] value is some measure that is a numeric value from 1 to 20. With this, he can easily create a simple skin that allows incremental changes to the mouse sensitivity, without needing to use any third-party utilities.