amer0612 Posted May 15, 2008 Share Posted May 15, 2008 Hi All I disable my keyboard and mouse using BlockInput(1) at the start of my script... But what if something went wrong and the script did not stop executing (BlockInput(0) function was not reached therefore not executed)? Other than Ctrl-Alt-Del, is there other way to stop the execution of the script? Can anyone give me a piece of code? Thanks Gino Link to comment Share on other sites More sharing options...
epoy Posted May 15, 2008 Share Posted May 15, 2008 I don't think a script will help you. Since you cannot even use your keyboard, because of blocking it. Maybe you could just restart your pc. but if you already registered it to the registry, try using the safemode. And manualy delete your application from the registry. Sorry if i'm wrong Link to comment Share on other sites More sharing options...
d4rk Posted May 15, 2008 Share Posted May 15, 2008 Except Ctrl Alt Del, there's no key can break the BlockInput() if you want to decrease the bad luck, use a function to Disable BlockInput() if the Mouse haven't move for 10 or 20 secs, or similar that look at MousePos(), it's will be helpful [quote]Don't expect for a perfect life ... Expect a least troubles ones[/quote]Contact me : ass@kiss.toWhat I Have Done :Favorites Manager Mangage your favorite's folder, that's coolPC Waker For those who want to save stickersWebScipts Supporter For those who've just started with Web and WebScriptsTemporary Looker Simple but powerful to manage your Temporary folder, you know what you downloaded[UDF] _NumberFormat() Better performance on number display[UDF] _DirGet() What a folder contain [how many (hidden,normal,...) files], with one line of code[UDF] _IsPressEs() Just like _IsPress() but for a group of keys Link to comment Share on other sites More sharing options...
AoRaToS Posted May 17, 2008 Share Posted May 17, 2008 Sorry to bump... Is there a way to block keyboard input but not mouse input? s!mpL3 LAN Messenger Current version 2.9.9.1 [04/07/2019] s!mpL3 LAN Messenger.zip s!mpL3 Link to comment Share on other sites More sharing options...
d4rk Posted May 18, 2008 Share Posted May 18, 2008 get a loop to make it's easier, but this's the idea if _Ispress("20") then sleep(100) endif [quote]Don't expect for a perfect life ... Expect a least troubles ones[/quote]Contact me : ass@kiss.toWhat I Have Done :Favorites Manager Mangage your favorite's folder, that's coolPC Waker For those who want to save stickersWebScipts Supporter For those who've just started with Web and WebScriptsTemporary Looker Simple but powerful to manage your Temporary folder, you know what you downloaded[UDF] _NumberFormat() Better performance on number display[UDF] _DirGet() What a folder contain [how many (hidden,normal,...) files], with one line of code[UDF] _IsPressEs() Just like _IsPress() but for a group of keys Link to comment Share on other sites More sharing options...
crashdemons Posted May 18, 2008 Share Posted May 18, 2008 (edited) Except Ctrl Alt Del, there's no key can break the BlockInput()What about the "Power" key? Edit: you can always create a program to check if the current program is still running somehow - there are multiple ways to accomplish this - none of them quite simple. Edited May 18, 2008 by crashdemons My Projects - WindowDarken (Darken except the active window) Yahsmosis Chat Client (Discontinued) StarShooter Game (Red alert! All hands to battlestations!) YMSG Protocol Support (Discontinued) Circular Keyboard and OSK example. (aka Iris KB) Target Screensaver Drive Toolbar Thingy Rollup Pro (Minimize-to-Titlebar & More!) 2D Launcher physics example Ascii Screenshot AutoIt3 Quine Example ("Is a Quine" is a Quine.) USB Lock (Another system keydrive - with a toast.) Link to comment Share on other sites More sharing options...
d4rk Posted May 18, 2008 Share Posted May 18, 2008 What about the "Power" key?Yes, as it is, it's Powerful [quote]Don't expect for a perfect life ... Expect a least troubles ones[/quote]Contact me : ass@kiss.toWhat I Have Done :Favorites Manager Mangage your favorite's folder, that's coolPC Waker For those who want to save stickersWebScipts Supporter For those who've just started with Web and WebScriptsTemporary Looker Simple but powerful to manage your Temporary folder, you know what you downloaded[UDF] _NumberFormat() Better performance on number display[UDF] _DirGet() What a folder contain [how many (hidden,normal,...) files], with one line of code[UDF] _IsPressEs() Just like _IsPress() but for a group of keys Link to comment Share on other sites More sharing options...
McGod Posted May 18, 2008 Share Posted May 18, 2008 Create an OnAutoitExit Function that will kill blockinput Opt("OnExitFunc", "KillBlock") Func KillBlock () BlockInput(0) EndFunc [indent][center][u]Formerly Chip[/u][/center]~UDFs~[/indent][u]IRC.au3 - Allows you to connect to IRC ServersINetCon.au3 - Connects/Disconnects/Check Status of InternetHardware Key - Creates a unique hardware hashScriptComm - Allows you to communicate between scripts using WM_COPYDATA[/u][indent]~Programs~[/indent][indent]SimonAu3ForumsIRC Bot~Web Site~Web Autoit Example[/indent][indent][b][/b][/indent][u][/u] Link to comment Share on other sites More sharing options...
amer0612 Posted May 22, 2008 Author Share Posted May 22, 2008 Actually I am looking for a way to monitor the script... That is if the execution time of the script exceeds a certain time it should be terminated.... (ex. if the script is running for more than 30 seconds terminate the program) Is there a way for this? Thanks Link to comment Share on other sites More sharing options...
d4rk Posted May 22, 2008 Share Posted May 22, 2008 $timer=timerInit() Do ;your script here Until TimerDiff($timer)>=30000 [quote]Don't expect for a perfect life ... Expect a least troubles ones[/quote]Contact me : ass@kiss.toWhat I Have Done :Favorites Manager Mangage your favorite's folder, that's coolPC Waker For those who want to save stickersWebScipts Supporter For those who've just started with Web and WebScriptsTemporary Looker Simple but powerful to manage your Temporary folder, you know what you downloaded[UDF] _NumberFormat() Better performance on number display[UDF] _DirGet() What a folder contain [how many (hidden,normal,...) files], with one line of code[UDF] _IsPressEs() Just like _IsPress() but for a group of keys 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