Skip to main content
Tab

ASPxGridViewBehaviorSettings.EnableCustomizationWindow Property

Specifies whether the Customization Window is enabled.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v23.2.dll

NuGet Package: DevExpress.Web

Declaration

[DefaultValue(false)]
public bool EnableCustomizationWindow { get; set; }

Property Value

Type Default Description
Boolean false

true to enable the Customization Window; otherwise, false.

Property Paths

You can access this nested property as listed below:

Object Type Path to EnableCustomizationWindow
ASPxGridView
.SettingsBehavior .EnableCustomizationWindow
GridViewProperties
.SettingsBehavior .EnableCustomizationWindow

Remarks

Set the EnableCustomizationWindow property to true to enable the Customization Window (the Column Chooser). A user can drag a column’s header to the Column Chooser or to the grid’s header to control the column’s visibility within the grid.

ASPxGridView - CustomizationWindow

Run Demo: ASPxGridView - Column Chooser

Use the following client-side API to control the visibility of the Column Chooser:

ShowCustomizationWindow
Shows the Column Chooser
HideCustomizationWindow
Hides the Column Chooser
IsCustomizationWindowVisible
Indicates whether the Column Chooser is visible

To specify the position and behavior of the Column Chooser, use the CustomizationWindow property.

<dx:ASPxGridView ID="ASPxGridView1" runat="server" AutoGenerateColumns="False" KeyFieldName="CustomerID"
    ClientInstanceName="clientGrid">
    <Columns>
        <dx:GridViewDataTextColumn FieldName="CustomerID" ReadOnly="True" Visible="false" />
        <dx:GridViewDataTextColumn FieldName="ContactName" VisibleIndex="0" />
        <dx:GridViewDataTextColumn FieldName="CompanyName" VisibleIndex="1" />
        <dx:GridViewDataTextColumn FieldName="Address" Visible="false" />
        <dx:GridViewDataTextColumn FieldName="City" VisibleIndex="2" />
        <dx:GridViewDataTextColumn FieldName="Region" Visible="false" />
        <dx:GridViewDataTextColumn FieldName="Country" VisibleIndex="3" />
        <dx:GridViewDataTextColumn FieldName="Phone" Visible="false" />
    </Columns>
    <SettingsPopup>
        <CustomizationWindow PopupAnimationType="Slide" />
    </SettingsPopup>
    <SettingsBehavior EnableCustomizationWindow="true" />
</dx:ASPxGridView>
<br />
<dx:ASPxButton ID="ASPxButton1" runat="server" Text="Column chooser" AutoPostBack="false">
    <ClientSideEvents Click="OnButtonClick" />
</dx:ASPxButton>
function OnButtonClick(s, e) {
    if (clientGrid.IsCustomizationWindowVisible())
        clientGrid.HideCustomizationWindow();
    else 
        clientGrid.ShowCustomizationWindow();
}

For mobile devices, we recommend that you use the Customization Dialog. Online Demo: ASPxGridView - Customization Dialog

See Also