HockeyFan Posted October 17, 2006 Posted October 17, 2006 Please Help!! (Novice) How do I write a script that will loop unil the {ENTER} key is pressed? Do ControlDisable ( " User Information", "OK", 6) Until <--------------------------------------------------------(the ENTER key is pressed) ControlEnable ( " User Information", "OK", 6) Thanks in advance!
HockeyFan Posted October 17, 2006 Author Posted October 17, 2006 see _IsPressed() in help8) My bad!I looked in the Help file but I missed the underscore! Thanks!
HockeyFan Posted October 17, 2006 Author Posted October 17, 2006 see _IsPressed() in help 8) OK, now what am I doing wrong!! I've used the example in the Help file but when I press the enter key, nothing happens. Here's my script so far...: $dll = DllOpen("C:\WINDOWS\system32\user32.dll") Do ControlDisable ( " User Information", "OK", 6) Until _IsPressed("2B", $dll) ControlEnable ( " User Information", "OK", 6) DllClose($dll)
Valuater Posted October 17, 2006 Posted October 17, 2006 per help... there is an include #Include <Misc.au3> _IsPressed($s_hexKey[, $v_dll = 'user32.dll']) 8)
HockeyFan Posted October 17, 2006 Author Posted October 17, 2006 per help... there is an include #Include <Misc.au3> _IsPressed($s_hexKey[, $v_dll = 'user32.dll']) 8) Yes! I have that at the beginning of my script...I just did not include it in the example I posted...sorry! :"> Any further ideas?
Valuater Posted October 17, 2006 Posted October 17, 2006 Until <--------------------------------------------------------(the ENTER key is pressed) 2B = EXECUTE key you want 0D = ENTER key 8)
HockeyFan Posted October 17, 2006 Author Posted October 17, 2006 Until <--------------------------------------------------------(the ENTER key is pressed)2B = EXECUTE keyyou want 0D = ENTER key8)Thank you :"> Works like a charm!! Thanks for your help!
Xenobiologist Posted October 17, 2006 Posted October 17, 2006 Hi, I think it would be better to disable the Control only one time and then do busy waiting for _isPressed Enter and If it is pressed then enable the Control. So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times
Valuater Posted October 17, 2006 Posted October 17, 2006 Hi,I think it would be better to disable the Control only one time and then do busy waiting for _isPressed Enter and If it is pressed then enable the Control.So long,Megain other words.. place this "ControlDisable ( " User Information", "OK", 6)"before.."Do"and i agree also8)
HockeyFan Posted October 17, 2006 Author Posted October 17, 2006 in other words.. place this "ControlDisable ( " User Information", "OK", 6)" before.. "Do" and i agree also 8) OK...do you mean: $dll = DllOpen("C:\WINDOWS\system32\user32.dll") ControlDisable ( " User Information", "OK", 6) Do Sleep(100) Until _IsPressed("0D", $dll) $UserName = GUICtrlRead($UserInputBox) ControlEnable ( " User Information", "OK", 6) DllClose($dll) ??
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