igSplitButton
Namespace: Wisej.Web.Ext.Ignite
Assembly: Wisej.Web.Ext.Ignite (4.1.0.0)
Split buttons, also known as split drop down buttons, are useful when you want to provide a default action/command for a button but also need to supply other, secondary options.
- C#
- VB.NET
public class igSplitButton : igBase
Public Class igSplitButton
Inherits igBase
Constructors
igSplitButton()
Constructs a new instance of the igSplitButton class.
Example:
The following example creates a split button and adds its items through the Options object.
var button = new igSplitButton();
button.Options.items = new[]
{
new { name = "save", label = "Save" },
new { name = "saveAs", label = "Save As..." }
};
button.Options.defaultItemName = "save";
this.Controls.Add(button);
igSplitButton(options)
Constructs a new instance of the igSplitButton class using the specified options.
| Name | Type | Description |
|---|---|---|
| options | Object | Initial set of options passed to the igSplitButton widget: an anonymous object, a JSON string or a dynamic object. |
Example:
The following example creates a split button with three items. The item selected by the user becomes the new default item.
var button = new igSplitButton(new
{
items = new[]
{
new { name = "reply", label = "Reply" },
new { name = "replyAll", label = "Reply All" },
new { name = "forward", label = "Forward" }
},
defaultItemName = "reply",
swapDefaultEnabled = true
});
this.Controls.Add(button);