Spaghetti prog Posted December 9, 2004 Share Posted December 9, 2004 Basically what i want to do is to show a popup when i click on a button (sort of context menu just under the button). So I used Guicreate with WSpopup style. That is fine but i'd like to get rid of it if by click anywhere in the form or much better elsewhere ... You know like when you click on the start button, popup shows and if you change yout mind you just clik anywhere but on it Thanks for your help goto is evil Link to comment Share on other sites More sharing options...
killaz219 Posted December 9, 2004 Share Posted December 9, 2004 (edited) You could search the forum for _ispressed and use the left click hexEdit: Added link Edited December 9, 2004 by killaz219 Link to comment Share on other sites More sharing options...
CyberSlug Posted December 9, 2004 Share Posted December 9, 2004 Newest unstable allows... control-specific context menus. Here's a way to allow a context menu on left or right clicks... $GUI = GuiCreate("ExampleGUI") $button = GuiCtrlCreateButton("SomeButton", 100, 100, 100, 100) $buttoncontext = GUICtrlCreateContextMenu($button) GUICtrlCreateMenuitem("This is a context menu...",$buttoncontext) GuiSetState() While 1 $msg = GuiGetMsg() If $msg = -3 Then ExitLoop ElseIf $msg = $button Then $p = MouseGetPos() MouseClick("right", $p[0], $p[1]) EndIf WEnd Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! Link to comment Share on other sites More sharing options...
killaz219 Posted December 9, 2004 Share Posted December 9, 2004 (edited) Well cyber, if he uses the ispressed, he can do a click on anywhere in the screen will close it. But thats a good way to look at it Edited December 9, 2004 by killaz219 Link to comment Share on other sites More sharing options...
Spaghetti prog Posted December 10, 2004 Author Share Posted December 10, 2004 @killaz219: thank u for the ispress stuff,I shalll use it for other purpose @cyberslug: your solution is perfect. BTW 1000's thanks for your work on LBS wrapper. It should be incorporated in autoit since get/receivemsg seems unfortunately to be the only way to use this control porperly. goto is evil 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