Back to Devexpress

TileViewOptionsKanban.Groups Property

windowsforms-devexpress-dot-xtragrid-dot-views-dot-tile-dot-tileviewoptionskanban.md

latest5.5 KB
Original Source

TileViewOptionsKanban.Groups Property

A collection of manually created Kanban groups. Once this collection is not empty, the Kanban board only displays groups from this collection.

Namespace : DevExpress.XtraGrid.Views.Tile

Assembly : DevExpress.XtraGrid.v25.2.dll

NuGet Packages : DevExpress.Win.Grid, DevExpress.Win.Navigation

Declaration

csharp
[XtraSerializableProperty(XtraSerializationVisibility.Collection, true, true, false, 0, XtraSerializationFlags.DefaultValue)]
public KanbanGroupCollection Groups { get; }
vb
<XtraSerializableProperty(XtraSerializationVisibility.Collection, True, True, False, 0, XtraSerializationFlags.DefaultValue)>
Public ReadOnly Property Groups As KanbanGroupCollection

Property Value

TypeDescription
KanbanGroupCollection

A collection of manually created Kanban groups.

|

Property Paths

You can access this nested property as listed below:

Object TypePath to Groups
TileView

.OptionsKanban .Groups

|

Remarks

Automatic Groups

The TileView automatically generates groups for all unique values in the group column (TileView.ColumnSet.GroupColumn). When a group becomes empty (for instance, when you remove all tiles from a group), the TileView deletes this group.

Manual Groups

In Kanban layout mode, you can manually create groups (KanbanGroup) via the Groups collection to perform the following tasks:

  • Maintain the group’s lifetime. Created groups are not automatically removed.
  • Show only specific groups.
  • Customize settings of individual groups.

The following animation shows three created groups:

When you create groups, you need to specify group values with the KanbanGroup.GroupValue property. These group values correspond to the group column (TileView.Columns.GroupColumn). When you drag a tile from one group to another, this tile’s group value is changed (the TileView assigns the target group’s value to the tile’s GroupColumn).

The following example creates three KanbanGroups.

csharp
//Specify the group column, by which tiles are distributed between groups.
tileView.ColumnSet.GroupColumn = this.colStatus;

//Add three groups
tileView.OptionsKanban.Groups.Add(new KanbanGroup() { GroupValue = TaskStatus.ToDo, Caption="To Do" });
tileView.OptionsKanban.Groups.Add(new KanbanGroup() { GroupValue = TaskStatus.Planned });
tileView.OptionsKanban.Groups.Add(new KanbanGroup() { GroupValue = TaskStatus.Doing});
tileView.OptionsKanban.ShowGroupBackground = DefaultBoolean.True;
tileView.OptionsKanban.GroupFooterButton.Visible = DefaultBoolean.True;
tileView.OptionsKanban.GroupFooterButton.Text = "Add a new card";
//Hide the footer button for the third group.
tileView.OptionsKanban.Groups[2].FooterButton.Visible = DefaultBoolean.False;
vb
' Specify the group column, by which tiles are distributed between groups.
tileView.ColumnSet.GroupColumn = Me.colStatus
' Add three groups
tileView.OptionsKanban.Groups.Add(New KanbanGroup() With {
    .GroupValue = TaskStatus.ToDo,
    .Caption = "To Do"
})
tileView.OptionsKanban.Groups.Add(New KanbanGroup() With {
    .GroupValue = TaskStatus.Planned
})
tileView.OptionsKanban.Groups.Add(New KanbanGroup() With {
    .GroupValue = TaskStatus.Doing
})
tileView.OptionsKanban.ShowGroupBackground = DefaultBoolean.True
tileView.OptionsKanban.GroupFooterButton.Visible = DefaultBoolean.True
tileView.OptionsKanban.GroupFooterButton.Text = "Add a new card"
' Hide the footer button for the third group.
tileView.OptionsKanban.Groups(2).FooterButton.Visible = DefaultBoolean.False

The result is demonstrated in the image below. Tiles are distributed between the created groups according to their GroupColumn values.

KanbanGroup Features

  • Group visibility

  • Display order

  • Custom group captions and group backgrounds

  • Footer buttons in individual groups

  • Tile drag-and-drop

See Also

GetKanbanGroupByValue(Object)

Kanban Board

TileViewOptionsKanban Class

TileViewOptionsKanban Members

DevExpress.XtraGrid.Views.Tile Namespace