Skip to main content

RibbonBarItemSplitButton

Namespace: Wisej.Web.Ext.RibbonBar

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

Represents a split button in a RibbonBarGroup.

public class RibbonBarItemSplitButton : RibbonBarItemButton

Unlike the RibbonBarItemButton, which opens the drop down menu when clicked anywhere, the split button is made of two parts: clicking the main part fires the Click and ItemClick events, while clicking the arrow opens the drop down menu defined in MenuItems.

Example:

Creating a split button that executes the default action or shows more options:

var undo = new RibbonBarItemSplitButton { Name = "undo", Text = "Undo", ImageSource = "icon-undo" };
undo.MenuItems.Add(new MenuItem("Undo All") { Name = "undoAll" });
undo.Click += (s, e) => Undo();
undo.ItemClicked += (s, e) =>
{
if (e.MenuItem.Name == "undoAll")
UndoAll();
};
this.ribbonBarGroup1.Items.Add(undo);

Constructors​

Instance member RibbonBarItemSplitButton()​

Initializes a new instance of RibbonBarItemSplitButton.

Methods​

Protected member OnWebEvent(e)​

Processes the event from the client.

ParameterTypeDescription
eWisejEventArgsEvent arguments.

Protected member OnWebRender(config)​

Renders the client component.

ParameterTypeDescription
configObjectDynamic configuration object.

Implements​