menu

Xamarin.Android

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class GridModel - Xamarin.Android API Reference | Syncfusion

    Show / Hide Table of Contents

    Class GridModel

    Represents a wrapper class for a SfDataGrid control handling the collection and view related operations.

    Inheritance
    System.Object
    GridModel
    Implements
    System.IDisposable
    Namespace: Syncfusion.SfDataGrid
    Assembly: Syncfusion.SfDataGrid.Android.dll
    Syntax
    public class GridModel : Object, IDisposable
    Remarks

    GridModel listens to the collection changes in a SfDataGrid control and responds to them. It updates the View in response to the collection changes.

    Constructors

    GridModel(SfDataGrid)

    Initializes a new instance of the GridModel class.

    Declaration
    public GridModel(SfDataGrid grid)
    Parameters
    Type Name Description
    SfDataGrid grid

    The reference of the SfDataGrid.

    Properties

    IsInSort

    Gets a value indicating whether the SortColumnDescriptions is changing.

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

    A boolean value denoting whether the SortColumnDescriptions is changing.

    Methods

    CollapseGroup(Group)

    Method which helps to collapse the specific group by passing the corresponding group.

    Declaration
    public bool CollapseGroup(Group group)
    Parameters
    Type Name Description
    Group group

    The group to be collapsed.

    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether this collapsing action is succeeded or failed

    Dispose()

    Releases the resources used by the component.

    Declaration
    public void Dispose()

    Dispose(Boolean)

    Releases the unmanaged resources used by the component and optionally releases the managed resources.

    Declaration
    protected virtual void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    if true - release both managed and unmanaged resources; if false - release only unmanaged resources.

    ExpandGroup(Group)

    Method which helps to expand the specific group by passing the corresponding group.

    Declaration
    public bool ExpandGroup(Group group)
    Parameters
    Type Name Description
    Group group

    The group to be expanded.

    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether this expanding action is succeeded or failed

    MakeSort(GridColumn)

    Makes the sort and remove the sort in a SfDataGrid control. Executes when a header cell is touched if the AllowSorting property in SfDataGrid and the GridColumn associated with the header cell is true.

    Adds and clears SortColumnDescription in the SortColumnDescriptions collection in a SfDataGrid control.

    Declaration
    public void MakeSort(GridColumn gridColumn)
    Parameters
    Type Name Description
    GridColumn gridColumn

    A GridColumn object to be sorted.

    Exceptions
    Type Condition
    System.InvalidOperationException

    Mapping Name necessary for Sorting

    RefreshDataRow()

    Refreshes the data row in the view.

    Declaration
    public void RefreshDataRow()

    RefreshView()

    Refreshes the view.

    Declaration
    public void RefreshView()

    Implements

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