Negative1 Posted March 27, 2009 Posted March 27, 2009 Is it possible to close a msgbox with a hotkey? I used winclose in a function however it seams the function does not get called until the user closes the msgbox. What are we going to do tonight Brain?Same thing we do every night Pinky try to automate the world.
Aceguy Posted March 27, 2009 Posted March 27, 2009 why would you want to close you own created msgbox.?? [u]My Projects.[/u]Launcher - not just for games & Apps (Mp3's & Network Files)Mp3 File RenamerMy File Backup UtilityFFXI - Realtime to Vana time Clock
Negative1 Posted March 27, 2009 Author Posted March 27, 2009 why would you want to close you own created msgbox.??I want to put some troubleshooting hotkeys into my program. EG: press control + ~ and it closes the normal "user" screens and goes into troubleshooting mode. What are we going to do tonight Brain?Same thing we do every night Pinky try to automate the world.
picea892 Posted March 27, 2009 Posted March 27, 2009 It appears autoit msgbox always has a class of #32770 This works for me #Include <Misc.au3> $dll = DllOpen("user32.dll") MsgBox(0,"","I LOVE AUTOIT") While 1 ; esc if _IsPressed("1B", $dll) then winclose("[class:#32770]","") sleep(100) WEnd
Developers Jos Posted March 27, 2009 Developers Posted March 27, 2009 (edited) That Hotkey doesn't do didly. try this one liner script: MsgBox(0, "", "I LOVE AUTOIT") run it and hit ESC. same result. MsgBox() is a blocking Function so cannot be closed with a hotkey. Build your own GUI msgbox if anything like this is required. Jos Edited March 27, 2009 by Jos Chiitus 1 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Negative1 Posted March 27, 2009 Author Posted March 27, 2009 That Hotkey doesn't do didly.try this one liner script: MsgBox(0, "", "I LOVE AUTOIT")run it and hit ESC. same result.MsgBox() is a blocking Function so cannot be closed with a hotkey. Build your own GUI msgbox if anything like this is required.Josugh good grief....thanks Jos What are we going to do tonight Brain?Same thing we do every night Pinky try to automate the world.
TurionAltec Posted March 29, 2009 Posted March 29, 2009 Alternatively you could compile the script as a console app, then spew output to the console window using consolewrite()
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