sensalim Posted April 16, 2008 Posted April 16, 2008 Ok I don't have any script, lol... because I have no idea how. I want it to do start > settings > control panel > mouse > wheel (tab) "Roll the wheel one notch to scroll" (o) The following number of lines at a time: [ 1] (_) One screen at a time I want it to change from [ 1] to [ 6] Thanks.
Squirrely1 Posted April 16, 2008 Posted April 16, 2008 (edited) I used a program from Sysinternals and the Control Panel > Mouse - found these keys:RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop", "WheelScrollLines", "REG_SZ", "6");scroll 6 lines RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop", "WheelScrollLines", "REG_SZ", "-1"); scroll 1 pageEdit: It looks like it won't take effect without updating UserParameters somehow.This opens the control panel applet:Run("rundll32.exe shell32.dll,Control_RunDLL main.cpl @0") Edited April 16, 2008 by Squirrely1 Das Häschen benutzt Radar
sensalim Posted April 16, 2008 Author Posted April 16, 2008 (edited) "It looks like it won't take effect without updating UserParameters somehow." What do you mean, how? Edited April 16, 2008 by sensalim
Squirrely1 Posted April 16, 2008 Posted April 16, 2008 Probably the code you need is a DllCall or a WMI script, because just changing the values as they exist in the registry doesn't apply the changes immediately, but probably only after a reboot. Das Häschen benutzt Radar
ProgAndy Posted April 18, 2008 Posted April 18, 2008 (edited) Make a DLLCall to SystemParametersInfo with GLOBAL CONST $SPI_SETWHEELSCROLLLINES = 105 $SPIF_UPDATEINIFILE = 0x1 $SPIF_SENDWININICHANGE = 0x2 $SPIF_SENDCHANGE = $SPIF_SENDWININICHANGE $WHEEL_PAGESCROLL = 4294967295 ; Use this, if you want scroll one Screen at a time $linesToScroll = 6 ; Here come the lines $err = DllCall("user32.dll", "int", "SystemParametersInfo", _ "int", $SPI_SETWHEELSCROLLLINES, _ "int", $linesToScroll, _ "int", 0, _ "int", BitOR($SPIF_UPDATEINIFILE, $SPIF_SENDWININICHANGE)) If @error <> 0 Then MsgBox( 4096, "Dll Error!!!", "There was an error making the Dll call." & @CR & "Error Code: " & @error ) EndIf Edited April 18, 2008 by ProgAndy *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now