Tasmania Posted October 4, 2007 Share Posted October 4, 2007 I suppose if there is no function to remove mouse-trap, you can set it to the desktop dimensions, but that's an... um... improper... way of programming (at least the programming languages I come from).... but is there a way to un-set the trap? Spring it in a sense of words? Link to comment Share on other sites More sharing options...
weaponx Posted October 4, 2007 Share Posted October 4, 2007 I dont really understand what you mean by "trap". What code are you using to cause this? What are your intentions? Link to comment Share on other sites More sharing options...
Tasmania Posted October 4, 2007 Author Share Posted October 4, 2007 _MouseTrap under Misc.au3. I'm locking the mouse coordinates to a certain part of a window based on GetWinPos and some basic math, and the lock remains throughout execution of the script. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted October 4, 2007 Moderators Share Posted October 4, 2007 I suppose if there is no function to remove mouse-trap, you can set it to the desktop dimensions, but that's an... um... improper... way of programming (at least the programming languages I come from).... but is there a way to un-set the trap? Spring it in a sense of words?The demonstration in the helpfile shows you how to "untrap" it..._MouseTrap(coords) = Trap_MouseTrap() = UnTrap (Notice there is nothing in the params) Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Tasmania Posted October 4, 2007 Author Share Posted October 4, 2007 (edited) Helpfile? There's a help file for this? I have tried searching the AutoIt Help file for Mouse Trap and couldn't find anything... where is this help file? Edit: Found it! UDF's! This should make life easier... wahoo! Edited October 4, 2007 by Tasmania Link to comment Share on other sites More sharing options...
aslani Posted October 4, 2007 Share Posted October 4, 2007 Just click the Header of the Window and move it, it untraps the mouse, atleast for me it does. [font="Georgia"]Chances are, I'm wrong.[/font]HotKey trouble?Stringregexp GuideAutoIT Current Version Link to comment Share on other sites More sharing options...
Tasmania Posted October 4, 2007 Author Share Posted October 4, 2007 Just click the Header of the Window and move it, it untraps the mouse, atleast for me it does.Yes, that's not exactly what I meant.. I've got it with _MouseTrap(), which is exactly what I wanted, however I also didn't want my users to be able to "spring" it themselves like that, so I disabled access to the header of the window via mouse I'm evil... Link to comment Share on other sites More sharing options...
aslani Posted October 4, 2007 Share Posted October 4, 2007 Yes, that's not exactly what I meant.. I've got it with _MouseTrap(), which is exactly what I wanted, however I also didn't want my users to be able to "spring" it themselves like that, so I disabled access to the header of the window via mouse I'm evil...lol, you are [font="Georgia"]Chances are, I'm wrong.[/font]HotKey trouble?Stringregexp GuideAutoIT Current Version Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted October 4, 2007 Moderators Share Posted October 4, 2007 Just FYI, ctrl+alt+delete is going to "untrap" it as well. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Tasmania Posted October 4, 2007 Author Share Posted October 4, 2007 Hehe yeah, that I hope for. Actually, any command that takes focus away from the window "untraps" it, oddly enough, but I suppose that's inevitable. I could make sure it has focus and put a while in like so: While WinNotActive("Notes") WinActivate("Notes") WEnd But that's just... so... so mean... and really, the people who will be running it won't have that much knowledge in computers anyway... hehe, so it's kinda unneccessary. 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