New to Telerik UI for .NET MAUI? Start a free 30-day trial

.NET MAUI TreeDataGrid Columns Cell Templates

This article describes how to extend the functionality of the columns in the .NET MAUI TelerikDataGrid and define custom content and edit templates using the CellContentTemplate and CellEditTemplate properties.

  • CellContentTemplate (DataTemplate)—Defines the appearance of each cell associated with the concrete column. CellContentTemplate gives you the opportunity to wrap the text inside each DataGrid column. You can add a Label as a content of the Text, Template Column and wrap its text using the Label's LineBreakMode property.
  • CellContentTemplateSelector (DataTemplateSelector)—Defines a DataTemplateSelector instance that may be used to retrieve dynamic data templates on a per-cell basis.
  • CellEditTemplate (DataTemplate)—Defines the editor associated with the concrete column. The CellEditTemplate is displayed when the cell is in edit mode.

As the TreeDataGrid inhertis from the DataGrid, for a runnable example with CellContentTemplate and CellEditTemplate scenario, see the SDKBrowser Demo Application and go to DataGrid > Columns category.

See Also

In this article