Syncfusion.Grid.Windows
Members 


GridModel Class

This is the GridModel class that holds all data information about a grid and provides methods to completely initialize a grid and attach it later to a GridControlBase so that its contents can be rendered to the screen.
Object Model
GridModel ClassGridControlBase ClassGridModelBanneredRanges ClassGridBaseStylesMap ClassGridBaseStyle ClassGridCellModelCollection ClassGridCellModelBase ClassGridColHiddenCollection ClassGridColHidden ClassGridModelRowColOperations ClassGridModelColStylesIndexer ClassGridStyleInfo ClassGridColWidthCollection ClassGridColWidth ClassGridModelRowColSizeIndexer ClassGridModelCommandManager ClassGridModelCoveredRanges ClassGridCurrentCellInfo ClassGridCellRendererBase ClassGridModelCutPaste ClassGridData ClassGridModelStyleDataExchange ClassIGridModelDataProvider InterfaceGridModel.InternalGridDragDropData ClassGridModelFloatingCells ClassGridCellInfoCollection ClassGridCellInfo ClassGridRangeInfo ClassIGridModelEventsTarget InterfaceGridModelHideRowColsIndexer ClassGridModelHideRowColsIndexer ClassGridStyleInfo ClassGridModelMergeCells ClassGridModel ClassOperationFeedbackListener ClassGridModelOptions ClassGridProperties ClassGridRangeStyleCollection ClassGridRangeStyle ClassGridRowHeightCollection ClassGridRowHeight ClassGridModelRowColSizeIndexer ClassGridRowHiddenCollection ClassGridRowHidden ClassGridModelRowColOperations ClassGridModelRowStylesIndexer ClassGridStyleInfo ClassGridRangeInfo ClassGridRangeInfoList ClassGridRangeInfo ClassGridModelSelections ClassGridStyleInfo ClassGridModelTextDataExchange ClassIGridData Interface
Syntax
Remarks
A GridModel holds all data for a grid. You can initialize a GridModel and then attach it to one or more GridControlBase controls. If you share the same model among several GridControlBase controls, changes in the model will be automatically reflected in all associated controls.

If the user makes changes in one control, e.g. row heights or cell contents, the changes will be stored in the GridModel and events are raised that notify all associated controls about changes in the model so that each view can update its contents. This follows the Model-View-Controller pattern where data is separated from view.

GridModel offers many events that you can subscribe to and modify the default behavior of the grid. Typically, methods that are sent before the action is carried out allows you to adjust certain parameters or cancel the operation. These events usually end with an "ing" suffix, like "Changing". Events that are raised after the data in the model have been changed inform associated controls about the success of the operation. For example, if a GridControlBase receives a CellsChanged event, it will redraw the affected cells. Most of these events have a Syncfusion.ComponentModel.SyncfusionSuccessEventArgs.Success property that indicates if the operation finished successfully or failed to complete.

A GridModel holds a GridCellModelCollection that holds models for all cell types used in the grid. If a cell queries for a new cell type that is not found in the cell model collection, it tries to instantiate a GridCellModelBase object for the specific cell type. A QueryCellModel event is raised to allow you to create custom cell types on demand. But you can also instantiate cell models for custom cell types at initialization and add them to CellModels.

There is also a GridControl class that combines both GridModel and GridControlBase into one class. This gives you easier access to all methods of GridModel if you are working on a grid that does not need to support several views sharing the same model.

Inheritance Hierarchy
AssemblyVersion

Syncfusion.Grid.Windows: 17.3460.0.26

See Also