# MenuItem

Namespace: **Wisej.Web**

Assembly: **Wisej.Framework** (4.0.0.0)

* [Component](https://docs.wisej.com/api/wisej.base/general/wisej.base.component)
  * [Component](https://docs.wisej.com/api/wisej.web/general/wisej.web.component)
    * [BindableComponent](https://docs.wisej.com/api/wisej.web/general/wisej.web.bindablecomponent)
      * [Menu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menu)
        * [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem)

Represents an individual item that is displayed within a [MainMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.mainmenu) or [ContextMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.contextmenu).

{% tabs %}
{% tab title="C#" %}

```csharp
public class MenuItem : Menu, ICommandSource
```

{% endtab %}

{% tab title="VB.NET" %}

```visual-basic
Public Class MenuItem
    Inherits Menu
    Implements ICommandSource
```

{% endtab %}
{% endtabs %}

## Constructors

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem()

Initializes a [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) with a blank caption.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem(text)

Initializes a new instance of the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) class with a specified caption for the menu item.

| Name     | Type                                                          | Description                    |
| -------- | ------------------------------------------------------------- | ------------------------------ |
| **text** | [String](https://docs.microsoft.com/dotnet/api/system.string) | The caption for the menu item. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem(text, onClick)

Initializes a new instance of the class with a specified caption and event handler for the [Click](#click) event of the menu item.

| Name        | Type                                                                      | Description                                                                                                                              |
| ----------- | ------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| **text**    | [String](https://docs.microsoft.com/dotnet/api/system.string)             | The caption for the menu item.                                                                                                           |
| **onClick** | [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) | The [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) that handles the [Click](#click) event for this menu item. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem(text, onClick, shortcut)

Initializes a new instance of the class with a specified caption, event handler, and associated shortcut key for the menu item.

| Name         | Type                                                                             | Description                                                                                                                              |
| ------------ | -------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| **text**     | [String](https://docs.microsoft.com/dotnet/api/system.string)                    | The caption for the menu item.                                                                                                           |
| **onClick**  | [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler)        | The [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) that handles the [Click](#click) event for this menu item. |
| **shortcut** | [Shortcut](https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.shortcut) | One of the [Shortcut](https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.shortcut) values.                                      |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem(text, items)

Initializes a new instance of the class with a specified caption and an array of submenu items defined for the menu item.

| Name      | Type                                                                          | Description                                                                                                                                       |
| --------- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| **text**  | [String](https://docs.microsoft.com/dotnet/api/system.string)                 | The caption for the menu item.                                                                                                                    |
| **items** | [MenuItem\[\]](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) | An array of [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) objects that contains the submenu items for this menu item. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MenuItem(mergeType, mergeOrder, shortcut, text, onClick, onPopup, onSelect, items)

Initializes a new instance of the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) class with a specified caption; defined event-handlers for the [Click](#click), [Select](#select) and [Popup](#popup) events; a shortcut key; a merge type; and order specified for the menu item.

| Name           | Type                                                                             | Description                                                                                                                                       |
| -------------- | -------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| **mergeType**  | [MenuMerge](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menumerge)      | One of the [MenuMerge](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menumerge) values.                                                    |
| **mergeOrder** | [Int32](https://docs.microsoft.com/dotnet/api/system.int32)                      | The relative position that this menu item will take in a merged menu.                                                                             |
| **shortcut**   | [Shortcut](https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.shortcut) | One of the [Shortcut](https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.shortcut) values.                                               |
| **text**       | [String](https://docs.microsoft.com/dotnet/api/system.string)                    | The caption for the menu item.                                                                                                                    |
| **onClick**    | [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler)        | The [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) that handles the [Click](#click) event for this menu item.          |
| **onPopup**    | [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler)        | The [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) that handles the [Popup](#popup) event for this menu item.          |
| **onSelect**   | [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler)        | The [EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) that handles the [Select](#select) event for this menu item.        |
| **items**      | [MenuItem\[\]](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem)    | An array of [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) objects that contains the submenu items for this menu item. |

## Properties

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) AllowHtml

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets a value indicating that the control can display HTML in the Text property. (Default: `False`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) AutoShowLoader

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the application blocks the browser with a modal mask when this menu item is clicked and until the server is done processing the execution request. (Default: `False`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) BackColor

[Color](https://docs.microsoft.com/dotnet/api/system.drawing.color): Returns or sets the background color of the menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) CharacterCasing

[CharacterCasing](https://docs.wisej.com/api/wisej.web/editors/wisej.web.charactercasing): Returns or sets the case of the text to display to the user. (Default: `Normal`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Checked

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether a check mark appears next to the text of the menu item. (Default: `False`)

**Throws:**

* [ArgumentException](https://docs.microsoft.com/dotnet/api/system.argumentexception)\
  The [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) is a top-level menu or has children.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Command

[ICommand](https://docs.wisej.com/api/wisej.web/interfaces/wisej.web.icommand): Returns or sets the [ICommand](https://docs.wisej.com/api/wisej.web/interfaces/wisej.web.icommand) implementation to invoke. (Default: `null`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Enabled

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the menu item is enabled. (Default: `True`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Font

[Font](https://docs.microsoft.com/dotnet/api/system.drawing.font): Returns or sets the font of the menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) ForeColor

[Color](https://docs.microsoft.com/dotnet/api/system.drawing.color): Returns or sets the text color of the menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Form

[Form](https://docs.wisej.com/api/wisej.web/containers/form): Returns the [Form](https://docs.wisej.com/api/wisej.web/containers/form) that owns the [Menu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menu).

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Icon

[Image](https://docs.microsoft.com/dotnet/api/system.drawing.image): Returns or sets the icon that is displayed by [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) IconSource

[String](https://docs.microsoft.com/dotnet/api/system.string): Returns or sets the theme name or URL for the icon to display in the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Index

[Int32](https://docs.microsoft.com/dotnet/api/system.int32): Returns or sets a value indicating the position of the menu item in its parent menu.

**Throws:**

* [ArgumentOutOfRangeException](https://docs.microsoft.com/dotnet/api/system.argumentoutofrangeexception)\
  The assigned value is less than zero or greater than the item count.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) IsParent

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns a value indicating whether the menu item contains child menu items.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MdiList

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the menu item will be populated with a list of the Multiple Document Interface (MDI) child windows that are displayed within the associated form. (Default: `False`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) MenuID

[Int32](https://docs.microsoft.com/dotnet/api/system.int32): Returns the unique identifier for this menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MergeOrder

[Int32](https://docs.microsoft.com/dotnet/api/system.int32): Returns or sets a value indicating the relative position of the menu item when it is merged with another. (Default: `0`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MergeType

[MenuMerge](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menumerge): Returns or sets a value indicating the behavior of this menu item when its menu is merged with another. (Default: `Add`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Parent

[Menu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menu): The parent menu that contains this menu item

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) RadioCheck

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem), if checked, displays a radio-button instead of a check mark. (Default: `False`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Shortcut

[Shortcut](https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.shortcut): Returns or sets a value indicating the shortcut key associated with the menu item. (Default: `None`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) ShowShortcut

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the shortcut key that is associated with the menu item is displayed next to the menu item caption. (Default: `True`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) SizeMode

[MenuItemSizeMode](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitemsizemode): Returns or sets how the menu item is resized when in a [MenuBar](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menubar) or [MainMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.mainmenu) (Default: `Auto`)

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) SourceControl

[Control](https://docs.wisej.com/api/wisej.web/general/control): Returns the [Control](https://docs.wisej.com/api/wisej.web/general/control) that owns the [ContextMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.contextmenu).

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Text

[String](https://docs.microsoft.com/dotnet/api/system.string): Returns or sets a value indicating the text of the menu item. Use "-" to display the menu separator.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Visible

[Boolean](https://docs.microsoft.com/dotnet/api/system.boolean): Returns or sets whether the menu item is visible. (Default: `True`)

## Methods

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) CloneMenu()

Creates a copy of the current [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

**Returns:** [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem). A [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) that represents the duplicated menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) CloneMenu(source, includeChildren)

Creates a copy of the specified [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

| Parameter                                                                                                                                                                                                                         | Type                                                                      | Description                                                                                                          |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
| **source**                                                                                                                                                                                                                        | [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) | The [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) that represents the menu item to copy. |
| **includeChildren** ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-723b640963c6cd781ff8c5ce5b24149fa0af7b9c%2Fbadge-optional.svg?alt=media) | [Boolean](https://docs.microsoft.com/dotnet/api/system.boolean)           | Indicates whether to clone the menu's child items.                                                                   |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) Dispose(disposing)

Disposes of the resources (other than memory) used by the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

| Parameter     | Type                                                            | Description                                                                 |
| ------------- | --------------------------------------------------------------- | --------------------------------------------------------------------------- |
| **disposing** | [Boolean](https://docs.microsoft.com/dotnet/api/system.boolean) | true when this method is called by the application rather than a finalizer. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) MergeMenu()

Merges this [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) with another [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) and returns the resulting merged [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem).

**Returns:** [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem). A [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem) that represents the merged menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnBackColorChanged(e)

Fires the [BackColorChanged](#backcolorchanged) event.

| Parameter | Type                                                                | Description                                                                                         |
| --------- | ------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | A [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnCheckedChanged(e)

Fires the [CheckedChanged](#checkedchanged) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnClick(e)

Fires the [Click](#click) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnCommandChanged(e)

Fires the [CommandChanged](#commandchanged) event.

| Parameter | Type                                                                | Description                                                                                         |
| --------- | ------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | A [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnFontChanged(e)

Fires the [FontChanged](#fontchanged) event.

| Parameter | Type                                                                | Description                                                                                         |
| --------- | ------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | A [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnForeColorChanged(e)

Fires the [ForeColorChanged](#forecolorchanged) event.

| Parameter | Type                                                                | Description                                                                                         |
| --------- | ------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | A [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnInitMenuPopup(e)

Fires the [Popup](#popup) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnPopup(e)

Fires the [Popup](#popup) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnSelect(e)

Fires the [Select](#select) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

This event fires only if there is an handler attached to it. A simple overload of the On\[Event] method in a derived class will not be invoked unless there is at least one handler attached to the event.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnTextChanged(e)

Fires the [TextChanged](#textchanged) event.

| Parameter | Type                                                                | Description                                                                                          |
| --------- | ------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| **e**     | [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) | An [EventArgs](https://docs.microsoft.com/dotnet/api/system.eventargs) that contains the event data. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnWebEvent(e)

Processes the event from the client.

| Parameter | Type                                                                           | Description      |
| --------- | ------------------------------------------------------------------------------ | ---------------- |
| **e**     | [WisejEventArgs](https://docs.wisej.com/api/wisej.core/general/wisejeventargs) | Event arguments. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-9bf7fa01e02f4da0f9ef90d3b049ae43e664919e%2Fprotected.png?alt=media) OnWebRender(config)

Renders the client component.

| Parameter  | Type                                                          | Description                   |
| ---------- | ------------------------------------------------------------- | ----------------------------- |
| **config** | [Object](https://docs.microsoft.com/dotnet/api/system.object) | Dynamic configuration object. |

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) PerformClick()

Generates a [Click](#click) event for the [MenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.menuitem), simulating a click by a user.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) PerformSelect()

Fires the [Select](#select) event for this menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Update()

Updates the component on the client.

## Events

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) BackColorChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [BackColor](#backcolor) property value changes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) CheckedChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [Checked](#checked) property value changes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Click

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the menu item is clicked or selected using a shortcut key or access key defined for the menu item.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) CommandChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [Command](#command) property value changes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) FontChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [Font](#font) property value changes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) ForeColorChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [ForeColor](#forecolor) property value changes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Popup

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Occurs before a menu item's list of menu items is displayed.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) Select

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the user places the pointer over a menu item.

This event fires only if there is an handler attached to it. A simple overload of the On\[Event] method in a derived class will not be invoked unless there is at least one handler attached to the event.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) TextChanged

[EventHandler](https://docs.microsoft.com/dotnet/api/system.eventhandler) Fired when the [Text](#text) property value changes.

## Inherited By

| Name                                                                                    | Description                                                                                                                                                                                                                                                                                                                                                                            |
| --------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [CheckedMenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.checkedmenuitem) | Represents an individual menu item that is displayed within a [MainMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.mainmenu) or [ContextMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.contextmenu) and always shows a checkbox next to the label.                                                                                                              |
| [LinkMenuItem](https://docs.wisej.com/api/wisej.web/menus/wisej.web.linkmenuitem)       | Represents an individual menu item that is displayed within a [MainMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.mainmenu) or [ContextMenu](https://docs.wisej.com/api/wisej.web/menus/wisej.web.contextmenu) rendered using the \<a> link element to let the browser process the specified [HRef](https://docs.wisej.com/api/wisej.web/wisej.web.linkmenuitem#href) URL. |

## Implements

| Name                                                                                                 | Description                                                                                                            |
| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| [IUserData](https://docs.wisej.com/api/wisej.web/interfaces/wisej.web.iuserdata)                     | Provides access to the `UserData` and `Tag` properties associated to the component implementing this interface.        |
| [IBindableComponent](https://docs.wisej.com/api/wisej.web/data-binding/wisej.web.ibindablecomponent) | Bindable components implement this interface.                                                                          |
| [ICommandSource](https://docs.wisej.com/api/wisej.web/interfaces/wisej.web.icommandsource)           | Defines an object that can invoke a [Command](https://docs.wisej.com/api/interfaces/wisej.web.icommandsource#command). |
| [IWisejComponent](https://docs.wisej.com/api/wisej.core/interfaces/wisej.core.iwisejcomponent)       | All wisej components implement this interface.                                                                         |
| [IWisejSerializable](https://docs.wisej.com/api/wisej.core/interfaces/wisej.core.iwisejserializable) | Allows an object to serialize itself.                                                                                  |
