Reflected Posted April 21, 2012 Share Posted April 21, 2012 Hello! im looking for x axis "lock" i found this, but was wondering if someone could make samething but for x axis (so mouse can go only up and down). Thanks forehand. HotKeySet("{f1}", "lockmouse" ) HotKeySet("{f2}", "unlockmouse" ) HotKeySet("{f3}", "exitprog" ) Global $yaxis = "525" Global $loop = 0 while 1 sleep( 100 ) Wend Func lockmouse() $loop = 1 while $loop = 1 $x = MouseGetPos ( 0 ) MouseMove ( $x, $yaxis , 0 ) Wend EndFunc Func unlockmouse() $loop = 0 EndFunc Func exitprog() exit EndFunc Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 21, 2012 Share Posted April 21, 2012 Hey Reflected!! Maybe This is what u want Thumbs Up if it helps u out #Include <Misc.au3> OnAutoItExitRegister('release') HotKeySet('^x','_xaxis') HotKeySet('^y','_yaxis') HotKeySet('^r','release') Func _xaxis() release() _MouseTrap(0 , @DesktopHeight/2 , @DesktopWidth , @DesktopHeight/2) EndFunc Func _yaxis() release() _MouseTrap( @DesktopWidth/2 , 0 , @DesktopWidth/2 , @DesktopHeight) EndFunc Func release() _MouseTrap() EndFunc While 1 Sleep(10^1011010101010110^10101010101010) WEnd My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
Reflected Posted April 21, 2012 Author Share Posted April 21, 2012 (edited) Okay got it working! Thanks alot! Edited April 21, 2012 by Reflected Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 21, 2012 Share Posted April 21, 2012 Ur Welcome My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
Mat Posted April 21, 2012 Share Posted April 21, 2012 "10^1011010101010110^10101010101010" ???? Even without the third number you are overflowing AutoIt's integers. The maximum sleep you can have will be less than 10^20 (2^64-1) and even then I'm not sure if it will work. Sleep(10) in a while loop works just as well AutoIt Project Listing Link to comment Share on other sites More sharing options...
PhoenixXL Posted April 21, 2012 Share Posted April 21, 2012 Yeah Very Rite Mat I just did it out of fun My code: PredictText: Predict Text of an Edit Control Like Scite. Remote Gmail: Execute your Scripts through Gmail. StringRegExp:Share and learn RegExp.Run As System: A command line wrapper around PSEXEC.exe to execute your apps scripts as System (LSA). Database: An easier approach for _SQ_LITE beginners. MathsEx: A UDF for Fractions and LCM, GCF/HCF. FloatingText: An UDF for make your text floating. Clipboard Extendor: A clipboard monitoring tool. Custom ScrollBar: Scroll Bar made with GDI+, user can use bitmaps instead. RestrictEdit_SRE: Restrict text in an Edit Control through a Regular Expression. Link to comment Share on other sites More sharing options...
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