GridGroupHeaderItem
The item which splits the groups (when utilizing the grouping feature of RadGrid) and provides expand/collapse functionality for them.
Created and meaningful only with grouping enabled.
Definition
Namespace:Telerik.Web.UI
Assembly:Telerik.Web.UI.dll
Syntax:
public class GridGroupHeaderItem : GridItem, IComponent, IDisposable, IParserAccessor, IUrlResolutionService, IDataBindingsAccessor, IControlBuilderAccessor, IControlDesignerAccessor, IExpressionsAccessor, IAttributeAccessor, INamingContainer
Inheritance: objectControlWebControlTableRowGridTableRowGridItemGridGroupHeaderItem...
Implements:
Inherited Members
Example:
Here is how you can get reference to the GridGroupHeaderItem on ItemDataBound:
Private Sub RadGrid1_ItemDataBound(sender As Object, e As Telerik.Web.UI.GridItemEventArgs)
If Typeof e.Item Is GridGroupHeaderItem Then
Dim item As GridGroupHeaderItem = CType(e.Item, GridGroupHeaderItem)
'do something here
End If
End Sub 'RadGrid1_ItemDataBound
private void RadGrid1_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
if ( e.Item is GridGroupHeaderItem )
{
GridGroupHeaderItem item = (GridGroupHeaderItem)e.Item;
//do something here
}
}
}
Constructors
Marked for internal usage only
public GridGroupHeaderItem(GridTableView ownerTableView, int itemIndex, int dataSetIndex)
Properties
Gets or sets all aggregate values in the header.
public IDictionary AggregatesValues { get; set; }
All aggregate values in the header.
The cell holding the content of the GridGroupHeaderItem
public TableCell DataCell { get; }
N/A
Created and meaningful only with grouping enabled.
Boolean property indicating whether the relevant GridGroupHeaderItem has child items inside the group it forms.
public override bool HasChildItems { get; }
boolean
Overrides:
Meaningful only with grouping enabled.
Methods
Method which returns the data items under the GridGroupHeaderItem group.
public GridItem[] GetChildItems()
GridItem[]
An array of GridItem instances
Meaningful only with grouping enabled.
protected GridGroupHeaderItem GetHeaderItemByGroupIndex(string GroupIndex)
Inherited from Control, for internal usage only
Inherited from Control, for internal usage only
public override void PrepareItemStyle()
Overrides:
Inherited from Control, for internal usage only
public override void SetupItem(bool dataBind, object dataItem, GridColumn[] columns, ControlCollection rows)
Overrides:
Method which shows/hides the items in the group designated by the GridGroupHeaderItem
[SuppressMessage("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
public override void SetVisibleChildren(bool value)
boolean, determines whether the items in the group will be displayed or hidden
Overrides:
Meaningful only with grouping enabled.