Blazor

Code Examples Upgrade Guide User Guide Demos Support Forums Download
  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class GridTemplates

    Show / Hide Table of Contents

    Class GridTemplates

    Configures grid templates.

    Inheritance
    System.Object
    GridTemplates
    Namespace: Syncfusion.Blazor.Grids
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class GridTemplates : OwningComponentBase

    Constructors

    GridTemplates()

    Declaration
    public GridTemplates()

    Properties

    DetailTemplate

    Gets or sets the template to customize detail row element.

    Declaration
    public RenderFragment<object> DetailTemplate { get; set; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Components.RenderFragment<System.Object>
    Remarks

    Use DetailTemplate to render hierarchy grid. It supports N level of nested grids. The parameters passed to the templates can be accessed using implicit parameter named context. The context is of type TValue.

    EmptyRecordTemplate

    Gets or sets the template to customize empty grid row element.

    Declaration
    public RenderFragment<EmptyRecordTemplateContext> EmptyRecordTemplate { get; set; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Components.RenderFragment<EmptyRecordTemplateContext>
    Remarks

    The parameters passed to the templates can be accessed using implicit parameter named context. The context is of type EmptyRecordTemplateContext.

    RowTemplate

    Gets or sets the row template to customize row elements.

    Declaration
    public RenderFragment<object> RowTemplate { get; set; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Components.RenderFragment<System.Object>
    Remarks

    The RowTemplate content must be TD elements and the number of TD elements must match the number of datagrid columns. The parameters passed to the templates can be accessed using implicit parameter named context. The context is of type TValue.

    ToolbarTemplate

    Render custom toolbar using ToolbarTemplate property. It replaces the in-built toolbar and click actions must be handled in custom toolbar itself.

    Declaration
    public RenderFragment<object> ToolbarTemplate { get; set; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Components.RenderFragment<System.Object>
    Remarks

    The parameters passed to the templates can be accessed using implicit parameter named context.

    Methods

    OnInitializedAsync()

    Declaration
    protected override Task OnInitializedAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved