Skip to main content

Sidebar

Namespace: Wisej.Web.Ext.Webix

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

Webix Sidebar is a Tree-based component which is used for creating menus with hierarchical structure.

public class Sidebar : wxBase

Constructors​

Constructs a new instance of the Sidebar class.

Example:

The following example creates a sidebar with three menu items.

var sidebar = new Sidebar();
sidebar.Options.data = new[]
{
new { id = "customers", icon = "wxi-user", value = "Customers" },
new { id = "orders", icon = "wxi-folder", value = "Orders" },
new { id = "calendar", icon = "wxi-calendar", value = "Calendar" }
};
sidebar.Dock = DockStyle.Left;
sidebar.Width = 220;
this.Controls.Add(sidebar);

Constructs a new instance of the Sidebar class.

NameTypeDescription
optionsObjectInitial set of options.

Example:

The following example creates a sidebar with a hierarchical menu; the nested data collection defines the sub items.

var sidebar = new Sidebar(new
{
data = new object[]
{
new { id = "dashboard", icon = "wxi-columns", value = "Dashboard" },
new
{
id = "reports",
icon = "wxi-folder",
value = "Reports",
data = new[]
{
new { id = "sales", value = "Sales" },
new { id = "costs", value = "Costs" }
}
}
}
});
sidebar.Dock = DockStyle.Left;
sidebar.Width = 220;
this.Controls.Add(sidebar);

Implements​