sortingdatagridheaderfilteringmudblazor

I want to remove 3 dots(option) from Header in MudDataGrid using MudBlazor


I am using MudDataGrid where I want only default sorting And overall filtering but I want to three dots (option) next to sorting and filtering icon. I have given Filterable="true" and SortMode="SortMode.Single" and not specified anything to display for three dots but three dots option coming automatically, is there a way to set three dots options to false so that three dots can be removed from display of MudDataGrid.

reference

I want to remove three dots options in overall Table Filtering. The filter I used is below: enter image description here

ReproductionLink: https://try.mudblazor.com/snippet/wkweEDbhGJvPWuVi


Solution

  • Use ShowColumnOptions=false to hide the options. You can set it for the whole datagrid or column wise MudDataGrid API

    <MudDataGrid Items="@Elements.Take(4)" Filterable="true" ShowColumnOptions="false">
        <Columns>
            <PropertyColumn Property="x => x.Number" Title="Nr" />
            <PropertyColumn Property="x => x.Sign" />
            <PropertyColumn Property="x => x.Name" />
            <PropertyColumn Property="x => x.Position" />
            <PropertyColumn Property="x => x.Molar" Title="Molar mass" />
        </Columns>
    </MudDataGrid>
    

    Snippet