NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

MenuItem Members

Public:

Constructor

MenuItem Constructor Overloaded. Initializes a new instance of the TBD class.

Properties

BarBreak Gets or sets a value indicating whether the item is placed on a new line (for a menu item added to a TBD object) or in a new column (for a submenu or menu displayed in a TBD).
Break Gets or sets a value indicating whether the item is placed on a new line (for a menu item added to a TBD object) or in a new column (for a submenu or menu displayed in a TBD).
Checked Gets or sets a value indicating whether a checkmark appears beside the text of the menu item.
DefaultItem Gets or sets a value indicating whether the menu item is the default.
Enabled Gets or sets a value indicating whether the menu item is enabled.
Handle (inherited from Menu) The HMENU handle corresponding to this menu.
Index Gets or sets the menu item's position in its parent menu.
IsParent Gets a value indicating whether the menu item contains child menu items.
MDIList Gets or sets a value indicating whether the menu item will be populated with a list of the MDI child windows that are displayed within the associated form.
MDIListItem (inherited from Menu) The MenuItem that contains the list of MDI child windows.
Menu Gets the menu in which this menu item appears.
MenuItems (inherited from Menu) [To be supplied.]
MergeOrder Gets or sets the relative position the menu item when its menu is merged with another.
MergeType Gets or sets a value that indicates the behavior of this menu item when its menu is merged with another.
OwnerDraw Gets or sets a value indicating whether code that you provide draws the menu item or Windows draws the menu item.
Parent Gets the menu in which this menu item appears.
RadioCheck Gets or sets a value that indicates whether the menu item, if checked, displays a radio-button mark instead of a check mark.
Shortcut Gets or sets the shortcut key associated with the menu item.
ShowShortcut Gets or sets a value that indicates whether the shortcut key that is assocaited with the menu item is displayed next to the menu item caption.
Site (inherited from MarshalByRefComponent) Gets or sets the site of the component.
Text Gets or sets the text of the menu item.
Visible Gets or sets a value that indicates whether the menu item is visible on its parent menu.

Methods

CloneMenu Overloaded. Creates a copy of the menu item.
Dispose Disposes the MenuItem.
Equals (inherited from Object) Determines whether the specified Object is the same instance as the current Object. Subclasses are expected to override this method to support value equality (not reference equality).
FindMenuItem (inherited from Menu) [To be supplied.]
GetContainer (inherited from MarshalByRefComponent) Returns the component's container.
GetDesignMode (inherited from MarshalByRefComponent) Determines whether the component is currently in design mode.
GetHashCode (inherited from Object) Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
GetLifetimeService (inherited from MarshalByRefObject) This method is used return a lifetime service object that is used to control the lifetime policy to the object. For the default Lifetime service this will be an object of type ILease.
GetMainMenu (inherited from Menu) Returns the MainMenu item that contains this menu. The MainMenu is at the top of this menu's parent chain. Returns null if this menu is not contained in a MainMenu. This can occur if it's contained in a ContextMenu or if it isn't currently contained in any menu at all.
GetServiceObject (inherited from MarshalByRefComponent) The implementation of IServiceObjectProvider
GetType (inherited from Object) Gets the Type of the Object.
InitializeLifetimeService (inherited from MarshalByRefObject)  
MergeMenu Overloaded. Merges this menu item with another menu item.
PerformClick Generates a System.WinForms.Control.Click event for the MenuItem, simulating a click by a user.
PerformSelect Raises the System.WinForms.MenuItem.Select event for this menu item.
ToString (inherited from Menu) Returns a string representation for this control.

Events

Click Occurs when the menu item is clicked or selected using a shortcut key or accelerator key defined for the menu item.
DrawItem Occurs when when the property of a menu item is set to true and a request is made to draw the menu item.
MeasureItem Occurs when when the menu needs to know the size of a menu item before drawing it.
Popup Occurs before a menu item's list of menu items is displayed.
Select Occurs when the user hovers their mouse over a menu item or selects it with the keyboard but has not activated it.

Protected:

Properties

MenuID Gets the Windows identifier for this menu item.

Methods

CloneMenu (inherited from Menu) Sets this menu to be an identical copy of another menu.
CreateMenuHandle (inherited from Menu) [To be supplied.]
Finalize (inherited from Menu) [To be supplied.]
FindMergePosition (inherited from Menu) [To be supplied.]
MemberwiseClone (inherited from Object) Creates a shallow copy of the current Object.
OnClick Raises the System.WinForms.MenuItem.Click event.
OnDrawItem Raises the System.WinForms.MenuItem.DrawItem event.
OnMeasureItem Raises the System.WinForms.MenuItem.MeasureItem event.
OnPopup Raises the System.WinForms.MenuItem.Popup event.
OnSelect Raises the System.WinForms.MenuItem.Select event.
ProcessCmdKey (inherited from Menu) [To be supplied.]

Event Hookup:

Methods

AddOnClick Adds an event handler for the event.
AddOnDrawItem Adds an event handler for the event.
AddOnMeasureItem Adds an event handler for the event.
AddOnPopup Adds an event handler for the event.
AddOnSelect Adds an event handler for the event.
RemoveOnClick Removes an event handler that has been associated with the System.WinForms.MenuItem.Click event.
RemoveOnDrawItem Removes an event handler that has been associated with the System.WinForms.MenuItem.DrawItem event.
RemoveOnMeasureItem Removes an event handler that has been associated with the System.WinForms.MenuItem.MeasureItem event.
RemoveOnPopup Removes an event handler that has been associated with the System.WinForms.MenuItem.Popup event.
RemoveOnSelect Removes an event handler that has been associated with the System.WinForms.MenuItem.Select event.

See Also

MenuItem Class | System.WinForms Namespace