Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DialogDisplayOptions Struct

In This Article

Contains display options for a dialog.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
public readonly struct DialogDisplayOptions

#Remarks

The DialogDisplayOptions class contains display options that you can apply when invoke a dialog. To invoke collisions, you cannot specify the options directly. Call one of the class constructors to specify the options.

In the following code snippet, the DxGrid.ShowColumnChooser(DialogDisplayOptions) method displays the grid’s Column Chooser. The method accepts an object of the DialogDisplayOptions class that specifies the Chooser window’s target point.

<DxButton Text="Show Column Chooser" Click="@OnClick" />

<DxGrid @ref="@Grid" Data="@Data" >
    <Columns>
        <DxGridDataColumn FieldName="CompanyName" />
        <DxGridDataColumn FieldName="ContactName" />
        <DxGridDataColumn FieldName="ContactTitle"  />
        <DxGridDataColumn FieldName="City" />
        <DxGridDataColumn FieldName="Country" />
        <DxGridDataColumn FieldName="Phone" Visible="false" />
    </Columns>
</DxGrid>

@code {
    DxGrid Grid { get; set; }
    IEnumerable<Supplier> Data { get; set; }
    protected override async Task OnInitializedAsync() {
        Data = await NwindDataService.GetSuppliersAsync();
    }
    void OnClick() {
        // Display the Column Chooser at the point x=100, Y=100
        Grid.ShowColumnChooser(new DialogDisplayOptions(new System.Drawing.Point(100, 100)) );
    }
}
See Also