Table of Contents

Method Add

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

Add(string, Command)

Adds a new menu item with the specified title and command to the menu.

public virtual MenuItem Add(string title, Command command)

Parameters

title string

The title of the menu item.

command Command

The command to execute when the menu item is clicked.

Returns

MenuItem

The created menu item.

Add(string, Action)

Creates and adds new item to Items collection.

public virtual MenuItem Add(string title, Action onClick)

Parameters

title string

Item title.

onClick Action

Item click action.

Returns

MenuItem

Created item.