Syncfusion.Grid.Windows


QueryCellModel Event (GridControl)

Occurs when the GridModel.QueryCellModel is querying for the GridCellModelBase based on a string cellType.
Syntax
'Declaration
 
<CategoryAttribute("Grid")>
<DescriptionAttribute("Occurs when GridModel.QueryCellModel is querying for the GridCellModelBase based on a string cellType")>
Public Event QueryCellModel As GridQueryCellModelEventHandler
'Usage
 
Dim instance As GridControl
Dim handler As GridQueryCellModelEventHandler
 
AddHandler instance.QueryCellModel, handler
[Category("Grid")]
[Description("Occurs when GridModel.QueryCellModel is querying for the GridCellModelBase based on a string cellType")]
public event GridQueryCellModelEventHandler QueryCellModel
Event Data

The event handler receives an argument of type GridQueryCellModelEventArgs containing data related to this event. The following GridQueryCellModelEventArgs properties provide information specific to this event.

PropertyDescription
Gets or sets the GridCellModelBase for the cell type. You should create a new instance of the specific cell model and save it to this property.  
Gets the cell type identifier as used in the CellType property.  
Gets GridModel. (Inherited from Syncfusion.Windows.Forms.Grid.GridModelEventArgs)
Remarks
The GridModel has a table with all cell types used in the grid. Whenever the grid encounters a new cell type that it cannot find in the table, it will raise a GridModel.QueryCellModel event. The CellType identifies the name of the cell type. The GridQueryCellModelEventArgs.CellModel should receive the new instance of the associated cell object. This object will be stored in the table together with its name and reused among cells with the same CellType.

You should process this event if you want to add custom cell types and initialize these cell types on demand when associated cells are accessed the first time.

AssemblyVersion

Syncfusion.Grid.Windows: 17.3460.0.26

See Also