Func OldRighty() Run("WScript.exe " & chr(34) & "righty.vbs" & chr(34)) Dim $primary Dim $secondary $k = RegRead("HKEY_CURRENT_USER\Control Panel\Mouse", "SwapMouseButtons") If $k = 1 Then $primary = "right" $secondary = "left" Else ;normal (also case if could not read registry key) $primary = "left" $secondary = "right" EndIf MouseClick($primary,145,1139,2,30) EndFUnc Func NewRighty() ;' Run("CONTROL.EXE MAIN.CPL") Sleep(1750) ;' Dim $sAppTitle ;' $sAppTitle="Mouse Properties" WinActivate($sAppTitle) ;' Send("!S!A") ; switch primary & secondary buttons Sleep(250) ;' Send("^{TAB}") ; go to "schemes/customize" tab Sleep(250) ;' Send("!S^{END}!A") ; go to scheme-go top scheme,next,apply Sleep(250) ;' Send("!{F4}") ; close control panel Sleep(250) EndFunc BlockInput(1) NewRighty() BlockInput(0) Exit