menu

WPF

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class GridDataTable - WPF API Reference | Syncfusion

    Show / Hide Table of Contents

    Class GridDataTable

    Specifies the events and properties related to the GridDataTableModel.

    Inheritance
    System.Object
    NonFinalizeDisposable
    Disposable
    GridDataTable
    Implements
    System.IDisposable
    System.ComponentModel.ISupportInitialize
    Inherited Members
    NonFinalizeDisposable.Dispose()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Syncfusion.Windows.Controls.Grid
    Assembly: Syncfusion.Grid.Wpf.dll
    Syntax
    public class GridDataTable : Disposable, IDisposable, ISupportInitialize

    Constructors

    GridDataTable(GridDataTableModel)

    Initializes a new instance of the class.

    Declaration
    public GridDataTable(GridDataTableModel parentGroup)
    Parameters
    Type Name Description
    GridDataTableModel parentGroup

    The parent group.

    Properties

    GroupModel

    Gets the group model.

    Declaration
    public GridDataTopLevelGroup GroupModel { get; }
    Property Value
    Type Description
    GridDataTopLevelGroup

    The group model.

    HasConditionalFormats

    Gets a value indicating whether this instance has conditional formats.

    Declaration
    public bool HasConditionalFormats { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has conditional formats; otherwise, false.

    HasDetailsView

    Gets a value indicating whether this instance has detail view.

    Declaration
    public bool HasDetailsView { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has detail view; otherwise, false.

    HasExpressionColumns

    Gets a value indicating whether this instance has expression columns.

    Declaration
    public bool HasExpressionColumns { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has expression columns; otherwise, false.

    HasFilters

    Gets a value specifying if the Model has filters applied.

    Declaration
    public bool HasFilters { get; }
    Property Value
    Type
    System.Boolean

    HasGroups

    Gets a value indicating whether this instance has groups.

    Declaration
    public bool HasGroups { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has groups; otherwise, false.

    HasNestedTables

    Gets a value indicating whether this instance has nested tables.

    Declaration
    public bool HasNestedTables { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has nested tables; otherwise, false.

    HasStackedHeaders

    Gets a value indicating whether this instance has stacked headers.

    Declaration
    public bool HasStackedHeaders { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has stacked headers; otherwise, false.

    HasTableSummaries

    Gets a value indicating whether this instance has table summaries.

    Declaration
    public bool HasTableSummaries { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has table summaries; otherwise, false.

    HasUnboundColumns

    Gets a value indicating whether this instance has unbound columns.

    Declaration
    public bool HasUnboundColumns { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance has unbound columns; otherwise, false.

    IsDynamicBound

    Gets a value indicating whether this instance is dynamic bound.

    Declaration
    public bool IsDynamicBound { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance is dynamic bound; otherwise, false.

    Model

    Gets or sets the parent group.

    Declaration
    public GridDataTableModel Model { get; }
    Property Value
    Type Description
    GridDataTableModel

    The parent group.

    TotalColumnCount

    Gets the total column count.

    Declaration
    public int TotalColumnCount { get; }
    Property Value
    Type Description
    System.Int32

    The total column count.

    Methods

    BeginInit()

    Signals the object that initialization is starting.

    Declaration
    public void BeginInit()

    CollapseAll()

    Collapses all the nested tables for all the records.

    Declaration
    public void CollapseAll()

    CollapseAllDetailsViews()

    Collapses all the nested tables for all the records.

    Declaration
    public void CollapseAllDetailsViews()

    CollapseAllGroups()

    Collapses all groups.

    Declaration
    public void CollapseAllGroups()

    CollapseAllGroupsAtLevel(Int32)

    Collapses all groups at level.

    Declaration
    public void CollapseAllGroupsAtLevel(int level)
    Parameters
    Type Name Description
    System.Int32 level

    The level.

    CollapseAt(Int32)

    Collapses the nested table at specified record index.

    Declaration
    public void CollapseAt(int recordIndex)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    CollapseDetailsViewAt(Int32)

    Collapses the nested table at specified record index.

    Declaration
    public void CollapseDetailsViewAt(int recordIndex)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    CollapseGroup(Group)

    Collapses the group.

    Declaration
    public void CollapseGroup(Group group)
    Parameters
    Type Name Description
    Syncfusion.Windows.Data.Group group

    The group.

    Dispose(Boolean)

    Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

    Declaration
    protected override void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing
    Overrides
    NonFinalizeDisposable.Dispose(Boolean)

    EndInit()

    Signals the object that initialization is complete.

    Declaration
    public void EndInit()

    ExpandAll()

    Expands all the records with nested tables.

    Declaration
    public void ExpandAll()

    ExpandAllDetailsViews()

    Expands all the records with nested tables.

    Declaration
    public void ExpandAllDetailsViews()

    ExpandAllGroups()

    Expands all groups.

    Declaration
    public void ExpandAllGroups()

    ExpandAllGroupsAtLevel(Int32)

    Expands all groups at level.

    Declaration
    public void ExpandAllGroupsAtLevel(int level)
    Parameters
    Type Name Description
    System.Int32 level

    The level.

    ExpandDetailsViewAt(Int32)

    Expands the record at specified record index.

    Declaration
    public void ExpandDetailsViewAt(int recordIndex)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    Index of the record.

    ExpandGroup(Group)

    Expands the group.

    Declaration
    public void ExpandGroup(Group group)
    Parameters
    Type Name Description
    Syncfusion.Windows.Data.Group group

    The group.

    ExpandRecordAt(Int32)

    Expands the record at specified record index.

    Declaration
    public void ExpandRecordAt(int recordIndex)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    Index of the record.

    GetRecordFromRow(Int32)

    Gets the record from the actual row index present in the Grid. You could use this in MouseDown events.

    Declaration
    public object GetRecordFromRow(int rowIndex)
    Parameters
    Type Name Description
    System.Int32 rowIndex

    Index of the row.

    Returns
    Type
    System.Object

    GetUnboundValue(Int32, GridDataUnboundVisibleColumn)

    Gets the unbound value.

    Declaration
    public object GetUnboundValue(int recordIndex, GridDataUnboundVisibleColumn column)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    Index of the record.

    GridDataUnboundVisibleColumn column

    The column.

    Returns
    Type
    System.Object

    GetUnboundValue(Int32, Int32)

    Gets the unbound value.

    Declaration
    public object GetUnboundValue(int rowIdx, int colIdx)
    Parameters
    Type Name Description
    System.Int32 rowIdx

    The row idx.

    System.Int32 colIdx

    The col idx.

    Returns
    Type
    System.Object

    GetUnboundValue(Object, GridDataUnboundVisibleColumn)

    Gets the unbound value.

    Declaration
    public object GetUnboundValue(object record, GridDataUnboundVisibleColumn column)
    Parameters
    Type Name Description
    System.Object record

    The record.

    GridDataUnboundVisibleColumn column

    The column.

    Returns
    Type
    System.Object

    GetUnboundValue(Object, String)

    Gets the unbound value.

    Declaration
    public object GetUnboundValue(object record, string columnName)
    Parameters
    Type Name Description
    System.Object record

    The record.

    System.String columnName

    Name of the column.

    Returns
    Type
    System.Object

    GetValue(Int32, String)

    Gets the value of the column from the record. This method returns proper results for data when it is grouped / cached in edit mode.

    Declaration
    public object GetValue(int recordIndex, string columnName)
    Parameters
    Type Name Description
    System.Int32 recordIndex

    Index of the record.

    System.String columnName

    Name of the column.

    Returns
    Type
    System.Object

    GetValue(Object, String)

    Gets the value of the underlying record object.

    Declaration
    public object GetValue(object record, string columnName)
    Parameters
    Type Name Description
    System.Object record

    The record.

    System.String columnName

    Name of the column.

    Returns
    Type
    System.Object

    OnRaiseInitializingNewItem(GridDataInitializingNewItemEventArgs)

    Declaration
    protected virtual void OnRaiseInitializingNewItem(GridDataInitializingNewItemEventArgs args)
    Parameters
    Type Name Description
    GridDataInitializingNewItemEventArgs args

    OnRecordAdded(GridDataNewRecordAddedEventArgs)

    Declaration
    protected virtual void OnRecordAdded(GridDataNewRecordAddedEventArgs args)
    Parameters
    Type Name Description
    GridDataNewRecordAddedEventArgs args

    OnRecordAdding(GridDataNewRecordAddingEventArgs)

    Declaration
    protected virtual void OnRecordAdding(GridDataNewRecordAddingEventArgs args)
    Parameters
    Type Name Description
    GridDataNewRecordAddingEventArgs args

    OnRecordsSelectionChanged(GridDataRecordsSelectionChangedEventArgs)

    Raises the SelectionChanged event.

    Declaration
    protected virtual void OnRecordsSelectionChanged(GridDataRecordsSelectionChangedEventArgs e)
    Parameters
    Type Name Description
    GridDataRecordsSelectionChangedEventArgs e

    A GridSelectionChangedEventArgs that contains the event data.

    OnRecordsSelectionChanging(GridDataRecordSelectionChangingEventArgs)

    Declaration
    protected virtual void OnRecordsSelectionChanging(GridDataRecordSelectionChangingEventArgs e)
    Parameters
    Type Name Description
    GridDataRecordSelectionChangingEventArgs e

    Events

    ChildModelLoaded

    Declaration
    public event ChildModelLoadedEventHandler ChildModelLoaded
    Event Type
    Type
    ChildModelLoadedEventHandler

    CurrentCellChanged

    Occurs when the current cell is changed.

    Declaration
    public event GridDataCurentCellChangedEventHandler CurrentCellChanged
    Event Type
    Type
    GridDataCurentCellChangedEventHandler

    CurrentCellValidating

    Occurs when the current cell value is validating.

    Declaration
    public event GridDataCurrentCellValidatingEventHandler CurrentCellValidating
    Event Type
    Type
    GridDataCurrentCellValidatingEventHandler

    DetailsViewCollapsed

    Occurs when [details view collapsed].

    Declaration
    public event EventHandler<GridDataValueEventArgs<GridDataRecord>> DetailsViewCollapsed
    Event Type
    Type
    System.EventHandler<GridDataValueEventArgs<GridDataRecord>>

    DetailsViewCollapsing

    Occurs when [details view collapsing].

    Declaration
    public event EventHandler<GridDataValueCancelEventArgs<GridDataRecord>> DetailsViewCollapsing
    Event Type
    Type
    System.EventHandler<GridDataValueCancelEventArgs<GridDataRecord>>

    DetailsViewExpanded

    Occurs when [details view expanded].

    Declaration
    public event GridDataDetailsViewExpandedEventHandler DetailsViewExpanded
    Event Type
    Type
    GridDataDetailsViewExpandedEventHandler

    DetailsViewExpanding

    Occurs when [details view expanding].

    Declaration
    public event GridDataDetailsViewExpandingEventHandler DetailsViewExpanding
    Event Type
    Type
    GridDataDetailsViewExpandingEventHandler

    GroupCollapsed

    Occurs when the group is collapsed.

    Declaration
    public event GroupCollapsedEventHandler GroupCollapsed
    Event Type
    Type
    GroupCollapsedEventHandler

    GroupCollapsing

    Occurs when the group is collapsing.

    Declaration
    public event GroupCollapsingEventHandler GroupCollapsing
    Event Type
    Type
    GroupCollapsingEventHandler

    GroupedColumnsChanged

    Occurs when the grouped columns are changed.

    Declaration
    public event GridDataGroupedColumnsChangedEventHandler GroupedColumnsChanged
    Event Type
    Type
    GridDataGroupedColumnsChangedEventHandler

    GroupExpanded

    Occurs when the group is expanded.

    Declaration
    public event GroupExpandedEventHandler GroupExpanded
    Event Type
    Type
    GroupExpandedEventHandler

    GroupExpanding

    Occurs when the group is expanding.

    Declaration
    public event GroupExpandingEventHandler GroupExpanding
    Event Type
    Type
    GroupExpandingEventHandler

    InitializingNewItem

    Declaration
    public event GridDataInitializingNewItemEventHandler InitializingNewItem
    Event Type
    Type
    GridDataInitializingNewItemEventHandler

    RecordAdded

    Occurs when a new record is added from insert new record row

    Declaration
    public event GridDataNewRecordAddedEventHandler RecordAdded
    Event Type
    Type
    GridDataNewRecordAddedEventHandler

    RecordAdding

    Occurs when a new record is adding from insert new record row

    Declaration
    public event GridDataNewRecordAddingEventHandler RecordAdding
    Event Type
    Type
    GridDataNewRecordAddingEventHandler

    RecordAfterBeginEdit

    Occurs when the record completes the begin edit state.

    Declaration
    public event EventHandler<GridDataValueEventArgs<int>> RecordAfterBeginEdit
    Event Type
    Type
    System.EventHandler<GridDataValueEventArgs<System.Int32>>

    RecordBeforeBeginEdit

    Occurs when the record goes into begin edit state.

    Declaration
    public event EventHandler<GridDataValueCancelEventArgs<int>> RecordBeforeBeginEdit
    Event Type
    Type
    System.EventHandler<GridDataValueCancelEventArgs<System.Int32>>

    RecordCollapsed

    Occurs when the record is collapsed.

    Declaration
    public event EventHandler<GridDataValueEventArgs<GridDataRecord>> RecordCollapsed
    Event Type
    Type
    System.EventHandler<GridDataValueEventArgs<GridDataRecord>>

    RecordCollapsing

    Occurs when the record is collapsing.

    Declaration
    public event EventHandler<GridDataValueCancelEventArgs<GridDataRecord>> RecordCollapsing
    Event Type
    Type
    System.EventHandler<GridDataValueCancelEventArgs<GridDataRecord>>

    RecordDeleted

    Occurs when the record is deleted.

    Declaration
    public event GridDataRecordDeletedEventHandler RecordDeleted
    Event Type
    Type
    GridDataRecordDeletedEventHandler

    RecordDeleting

    Occurs when the record is deleting.

    Declaration
    public event GridDataRecordDeletingEventHandler RecordDeleting
    Event Type
    Type
    GridDataRecordDeletingEventHandler

    RecordEndEdit

    Occurs when the record completes the end edit.

    Declaration
    public event EventHandler<GridDataValueEventArgs<int>> RecordEndEdit
    Event Type
    Type
    System.EventHandler<GridDataValueEventArgs<System.Int32>>

    RecordExpanded

    Occurs when the record is expanded.

    Declaration
    public event EventHandler<GridDataValueEventArgs<GridDataRecord>> RecordExpanded
    Event Type
    Type
    System.EventHandler<GridDataValueEventArgs<GridDataRecord>>

    RecordExpanding

    Occurs when the record is expanding.

    Declaration
    public event GridDataRecordExpandingEventHandler RecordExpanding
    Event Type
    Type
    GridDataRecordExpandingEventHandler

    RecordSelectionChanging

    Declaration
    public event GridDataRecordSelectionChangingEventHandler RecordSelectionChanging
    Event Type
    Type
    GridDataRecordSelectionChangingEventHandler

    RecordsSelectionChanged

    Occurs after the model updates its internal data structures when the model in the process of selecting a range of cells as a result of a SelectRange(GridRangeInfo, Boolean).

    Declaration
    public event GridDataRecordsSelectionChangedEventHandler RecordsSelectionChanged
    Event Type
    Type
    GridDataRecordsSelectionChangedEventHandler
    Remarks

    The GridModel will raise a SelectionChanging event before it updates its internal data structures and a SelectionChanged event after afterwards. A GridControlBase grid listens to this event and outline the selected range of cells.

    SortColumnsChanged

    Occurs when the sort columns are changed.

    Declaration
    public event GridDataSortColumnsChangedEventHandler SortColumnsChanged
    Event Type
    Type
    GridDataSortColumnsChangedEventHandler

    SortColumnsChanging

    Occurs when the sort columns are changing.

    Declaration
    public event GridDataSortColumnsChangingEventHandler SortColumnsChanging
    Event Type
    Type
    GridDataSortColumnsChangingEventHandler

    Implements

    System.IDisposable
    System.ComponentModel.ISupportInitialize
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved