User Tools

Site Tools


Changing the mouse speed

by Richard Russell, January 2011

You can change the mouse speed, that is how fast the mouse pointer moves when you physically move the mouse, as follows:

        SYS "SystemParametersInfo", SPI_SETMOUSESPEED, 0, speed%, 0

Where speed% has a value between 1 (slowest) and 20 (fastest). The default value is 10.

The above code changes the speed only for the current session. If you want to change the speed 'permanently' set the final parameter to 1:

        SYS "SystemParametersInfo", SPI_SETMOUSESPEED, 0, speed%, 1

Note that the mouse is a shared resourse, so any change you make will affect all applications and utilities, not just your program.

You can discover the current mouse speed setting as follows:

        SYS "SystemParametersInfo", SPI_GETMOUSESPEED, 0, ^speed%, 0

This will set speed% to the current value (note the very important ^ before the variable name).

This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information
changing_20the_20mouse_20speed.txt · Last modified: 2018/04/16 15:29 by richardrussell