MenuItem.GetParentMenu
----------------------

Returns the menu containing the menu item.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Menu](component_Menu.md) | [4.3](newinversion43.md) | ✅ Yes | ✅ Yes | ❌ No | ❌ No | ❌ No |

MBS( "MenuItem.GetParentMenu"; Item ) 

**MBS**( **"MenuItem.GetParentMenu";** /\* Returns the menu containing the menu item. \*/  
**$Item**) /\* The reference to the menu item. Please create one with [MenuItem.CreateMenuItem](MenuItemCreateMenuItem.md) or [MenuItem.CreateSeparator](MenuItemCreateSeparator.md). \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| Item | The reference to the menu item. Please create one with [MenuItem.CreateMenuItem](MenuItemCreateMenuItem.md) or [MenuItem.CreateSeparator](MenuItemCreateSeparator.md). | $item |

### Result

Returns menu reference number or error.

### Description

Returns the menu containing the menu item.  
The parent menu, or empty text if the item does not have a parent item.  
### See also

- [MenuItem.CreateMenuItem](MenuItemCreateMenuItem.md)
- [MenuItem.CreateSeparator](MenuItemCreateSeparator.md)
- [MenuItem.GetParentItem](MenuItemGetParentItem.md)

This function checks for a license.

Created 2nd September 2014 , last changed 9th November 2021

  
[MenuItem.GetParentItem](MenuItemGetParentItem.md) - [MenuItem.GetPath](MenuItemGetPath.md)

[HTML Version](MenuItemGetParentMenu.shtml)