ravenp Posted August 17, 2005 Share Posted August 17, 2005 Howdy. I've just created my first script in Autoit(thanks to those that helped me get over the hump!). Now i'm getting feedback that because the user could start typing or moving their mouse and disrupt the script, it's not good enough. Is there a way to disable mouse/keyboard control for the execution of my script? Thanks! Link to comment Share on other sites More sharing options...
DaleHohm Posted August 17, 2005 Share Posted August 17, 2005 Look in the helpfile for BlockInput Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
Eviltim Posted August 17, 2005 Share Posted August 17, 2005 BlockInput ( flag ) 1=Disable user input 0=Enable user input so put BlockInput(1) at the beggining of your script and BlockInput(0) at the end. search the help file for a better explanation if needed. Link to comment Share on other sites More sharing options...
ravenp Posted August 17, 2005 Author Share Posted August 17, 2005 BlockInput ( flag )1=Disable user input0=Enable user inputso put BlockInput(1) at the beggining of your script andBlockInput(0) at the end.search the help file for a better explanation if needed. <{POST_SNAPBACK}>Wow, thanks for the quick replies guys! Link to comment Share on other sites More sharing options...
ravenp Posted August 17, 2005 Author Share Posted August 17, 2005 Wow, thanks for the quick replies guys!<{POST_SNAPBACK}> Works like a charm! Link to comment Share on other sites More sharing options...
seandisanti Posted August 17, 2005 Share Posted August 17, 2005 BlockInput ( flag )1=Disable user input0=Enable user inputso put BlockInput(1) at the beggining of your script andBlockInput(0) at the end.search the help file for a better explanation if needed. <{POST_SNAPBACK}>one thing to watch for (you probably would have figured this for yourself, but i didn't when i first used it) be careful if you have any error trapping, or any other kind of conditional early termination that you BlockInput(0) before you Exit. Also, in the event that you are working on script, or debugging later, and you run into a situation where input is blocked and you need to unblock it (like a logic error causes infinite loop while input blocked) press control alt delete (i've personally had to do it on XP and 2k, don't know if it works on other OS's) once you control alt delete, it unblocks inputs automatically, just wanted to tell you that so you don't get stuck rebooting, or end tasking your script unnecessarily. 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