Share this page

# MenuItem

# WPF. MenuItem

MenuItem

# Constructor

## new MenuItem()

A menu item in a .NET WPF menu.

### Methods

## exists() → {Promise.<boolean>}

Indicates whether this menu item exists.

##### Returns:

a promise that is fulfilled with the indication of whether this menu item exists.

Type
  Promise.<boolean>

## hasSubMenu() → {Promise.<boolean>}

Indicates whether this menu item contains a sub-menu.

##### Returns:

a promise that is fulfilled with the indication of whether this menu item contains a sub-menu.

Type
  Promise.<boolean>

## index() → {Promise.<number>}

The 1-based index of this menu item.

##### Returns:

a promise that is fulfilled with the 1-based index of this menu item.

Type
  Promise.<number>

## isChecked() → {Promise.<boolean>}

Indicates whether this menu item has a check mark displayed next to it.

##### Returns:

a promise that is fulfilled with the indication of whether this menu item has a check mark displayed next to it.

Type
  Promise.<boolean>

## isEnabled() → {Promise.<boolean>}

Indicates whether this menu item is currently enabled.

##### Returns:

a promise that is fulfilled with the indication of whether this menu item is currently enabled.

Type
  Promise.<boolean>

## label() → {Promise.<string>}

The menu item label as a string. If duplicate items exist, returns the index.

##### Returns:

a promise that is fulfilled with the menu item label as a string or the index if duplicate items exist.

Type
  Promise.<string>

## subMenuCount() → {Promise.<boolean>}

The number of items contained in this menu item's sub-menu.

##### Returns:

a promise that is fulfilled with the number of items contained in this menu item's sub-menu.

Type
  Promise.<boolean>

Tips to improve your search results... UFT Developer JavaScript SDK Reference Version 15.0-15.0.2 UFT Developer SDK Reference All View Local Help Center View Online Help Center back Go back in browser history forward Go forward in browser history Remove search highlights next topic Go to next topic previous topic Go to previous topic Print the current topic Version: