jonbell Posted November 30, 2006 Share Posted November 30, 2006 Hi, this is a first post... I designined a little app using power pro And I am trying to use autoit to develop a downloadable .exe of the same functionality. But Autoit does things in a different style, for example getting you to put everything on a gui.... How can I get my own "Context" Menu to appear at the cursor when I hold the right mouse button down, system wide? button down menu appears at cursor possition make selection menu goes away ..no OK button, no clunky border, no title, no minimize...... can I use Autoit for this? Link to comment Share on other sites More sharing options...
Zedna Posted January 27, 2007 Share Posted January 27, 2007 #include <GUIConstants.au3> ;right click on gui to bring up context Menu. ;right click on the "ok" button to bring up a controll specific context menu. GuiCreate("My GUI Context Menu",300,200,-1,-1,BitOR($WS_POPUP,$WS_BORDER),BitOr($WS_EX_TOPMOST,$WS_EX_TOOLWINDOW)) ;~ GUICreate("My GUI Context Menu", 300, 200) $contextmenu = GUICtrlCreateContextMenu () $button = GUICtrlCreateButton("OK", 100, 100, 70, 20) $buttoncontext = GUICtrlCreateContextMenu($button) $buttonitem = GUICtrlCreateMenuitem("About button", $buttoncontext) $newsubmenu = GUICtrlCreateMenu ("new", $contextmenu) $textitem = GUICtrlCreateMenuitem ("text", $newsubmenu) $fileitem = GUICtrlCreateMenuitem ("Open", $contextmenu) $saveitem = GUICtrlCreateMenuitem ("Save", $contextmenu) GUICtrlCreateMenuitem ("", $contextmenu) ; separator $infoitem = GUICtrlCreateMenuitem ("Info", $contextmenu) GUISetState () While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend Resources UDF ResourcesEx UDF AutoIt Forum Search 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