Skip to main content

Menu

Namespace: Wisej.Web.Ext.Syncfusion2

Assembly: Wisej.Web.Ext.Syncfusion2 (4.1.0.0)

The menu component is a graphical user interface that serves as navigation header for your application or site.

public class Menu : ej2Base

Constructors​

Constructs a new instance of the Menu class.

Example:

The following example creates a menu and defines its items through the Options object.

var menu = new Menu();
menu.Options.items = new[]
{
new { text = "File", items = new[] { new { text = "Open" }, new { text = "Save" } } },
new { text = "Edit", items = new[] { new { text = "Cut" }, new { text = "Copy" } } }
};
menu.Dock = DockStyle.Top;
this.Controls.Add(menu);

Constructs a new instance of the Menu class.

NameTypeDescription
optionsObjectInitial set of options.

Example:

The following example creates a vertical menu that opens the sub menus when the user clicks the parent item.

var menu = new Menu(new
{
orientation = "Vertical",
showItemOnClick = true,
items = new object[]
{
new { text = "Orders", items = new[] { new { text = "New Order" }, new { text = "Order History" } } },
new { text = "Customers" },
new { text = "Help" }
}
});
this.Controls.Add(menu);

Implements​