Class DataGridComboBoxRenderer
GridCellComboBoxRenderer is a class for cell renderer that displays SfDataGridLabel in a DataGridCell. The class provides strong typed override methods for initializing Content of the cell and arranging the cell visuals. Upon editing it displays SfComboBox for editing values.
Updates to appearance and Content of child elements, creation and unloading of views will not trigger layout or render calls in parent canvas.
Inherited Members
Namespace: Syncfusion.Maui.DataGrid
Assembly: Syncfusion.Maui.DataGrid.dll
Syntax
public class DataGridComboBoxRenderer : DataGridCellRenderer<SfDataGridLabel, SfComboBox>, IDataGridCellRenderer, IDisposable
Constructors
DataGridComboBoxRenderer()
Initializes a new instance of the DataGridComboBoxRenderer class.
Declaration
public DataGridComboBoxRenderer()
Methods
GetControlValue()
Returns the current cell value, only if the renderer's DataGridCellRendererBase.HasCurrentCellState is true.
Declaration
[RequiresUnreferencedCode("The GetControlValue method is not trim compatible")]
public override object? GetControlValue()
Returns
| Type | Description |
|---|---|
| object | The current cell value. |
Overrides
OnCreateDisplayUIView()
Creates a new SfDataGridLabel view and initializes it with the required properties.
Declaration
protected override SfDataGridLabel OnCreateDisplayUIView()
Returns
| Type | Description |
|---|---|
| SfDataGridLabel | A new LaDataGridCellViewbel view. |
Overrides
OnCreateEditUIView()
Creates a new view for the edit mode of cell.
Declaration
protected override SfComboBox OnCreateEditUIView()
Returns
| Type | Description |
|---|---|
| SfComboBox | Returns the new view for edit mode of cell. |
Overrides
OnInitializeEditView(DataColumnBase, SfComboBox)
Initialize the edit view and it's properties.
Declaration
[RequiresUnreferencedCode("The OnInitializeEditView method is not trim compatible")]
public override void OnInitializeEditView(DataColumnBase dataColumn, SfComboBox view)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfComboBox | view |
Overrides
OnUpdateCellValue(DataColumnBase)
Updates the cell value of the associated column.
Declaration
protected override void OnUpdateCellValue(DataColumnBase dataColumn)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn |
Overrides
ResumeBinding(DataColumnBase, SfDataGridLabel)
Resume the binding of a SfLabel view Syncfusion.Maui.DataGrid.DataColumn .
Declaration
[UnconditionalSuppressMessage("Trimming", "IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code", Justification = "The ResumeBinding method is not trim compatible")]
protected override void ResumeBinding(DataColumnBase dataColumn, SfDataGridLabel view)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfDataGridLabel | view |
Overrides
SetControlValue(object)
Set the current cell value, only if the renderer's DataGridCellRendererBase.HasCurrentCellState is true.
Declaration
public override void SetControlValue(object value)
Parameters
| Type | Name | Description |
|---|---|---|
| object | value |
Overrides
SuspendBinding(DataColumnBase, SfDataGridLabel)
Suspend the binding of a SfLabel view Syncfusion.Maui.DataGrid.DataColumn .
Declaration
protected override void SuspendBinding(DataColumnBase dataColumn, SfDataGridLabel view)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfDataGridLabel | view |
Overrides
UnwireEditUIElement(SfComboBox)
Unwires the edit element to the view.
Declaration
[UnconditionalSuppressMessage("Trimming", "IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code", Justification = "The ResumeBinding method is not trim compatible")]
protected override void UnwireEditUIElement(SfComboBox editElement)
Parameters
| Type | Name | Description |
|---|---|---|
| SfComboBox | editElement |
Overrides
UpdateEditViewCellStyle(DataColumnBase, SfComboBox)
Updates the cell style of the edit element in a grid cell.
Declaration
protected override void UpdateEditViewCellStyle(DataColumnBase dataColumn, SfComboBox editView)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfComboBox | editView |