Jump to content

GUI Menu items?


Recommended Posts

GUICtrlCreateMenu

--------------------------------------------------------------------------------

Creates a Menu control for the GUI.

GUICtrlCreateMenu ( "submenutext" [, menuID [, menuentry]] )

Parameters

submenutext The submenu text.

menuID [optional] If defined, allows you to create a submenu in the referenced menu. If equal -1 it refers to first level menu.

menuentry [optional] Allows you to define the entry number to be created. The entries are numbered starting at 0.

Return Value

Success: Returns the identifier (controlID) of the new control.

Failure: Returns 0.

GUICtrlCreateMenuItem

--------------------------------------------------------------------------------

Creates a MenuItem control for the GUI.

GUICtrlCreateMenuItem ( "text", menuID [, menuentry [, menuradioitem]] )

Parameters

text The text of the control.

menuID Allows you to create a submenu in the referenced menu. If equal -1 it refers to the first level menu.

menuentry [optional] Allows you to define the entry number to be created. The entries are numbered starting at 0.

menuradioitem [optional] 0 (default) = create a normal menuitem, 1 = create a menuradioitem

Return Value

Success: Returns the identifier (controlID) of the new control.

Failure: Returns 0.

Remarks

To set or change information in the control see GUICtrlSet....

If the Text parameter is a "" then a separator line is created. GUICtrlSetState can be used as for other controls. See example.

Quotes from AutoIt help file ...

SNMP_UDF ... for SNMPv1 and v2c so far, GetBulk and a new example script

wannabe "Unbeatable" Tic-Tac-Toe

Paper-Scissor-Rock ... try to beat it anyway :)

Link to comment
Share on other sites

  • Moderators

thescarsolife,

The info on these functions is in the Help file on the pages for GUICtrlCreateMenu and GUICtrlCreateMenuItem.

The Help file itself is opened (on my system at least) by running "C:\Program Files\AutoIt3\AutoIt3Help.exe". If you prefer, you can press F1 or use the "Help -> Help" menu in SciTE, as long as you have an active .au3 file loaded.

You will find the relevant pages by selecting the 'Contents' tab, and looking under "AutoIt -> Function Reference -> GUI Reference -> GUI Control Creation". Alternatively you could type GUICtrlCreateMenu or GUICtrlCreateMenuItem into the 'Index' tab search box. Or again you could type "menu" into the 'Search' tab search box, where they come up as items 22 and 33.

As for Koda, it is situated at "C:\Program Files\AutoIt3\Koda\FD.exe" in my standard AutoIt install.

I hope this answers your question.

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...