Back to Devexpress

DataViewCommandsBase.ShowColumnChooser Property

wpf-devexpress-dot-xpf-dot-grid-dot-dataviewcommandsbase-a9d99051.md

latest2.1 KB
Original Source

DataViewCommandsBase.ShowColumnChooser Property

Invokes the Column Chooser.

Namespace : DevExpress.Xpf.Grid

Assembly : DevExpress.Xpf.Grid.v25.2.Core.dll

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public ICommand ShowColumnChooser { get; }
vb
Public ReadOnly Property ShowColumnChooser As ICommand

Property Value

TypeDescription
ICommand

A command implementing the ICommand.

|

Remarks

Corresponding Method: DataViewBase.ShowColumnChooser.

The following example uses the ShowColumnChooser property to display Column Chooser:

xaml
xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"
xmlns:dxg="http://schemas.devexpress.com/winfx/2008/xaml/grid"
...
<Grid>
    <Grid.RowDefinitions>
        <RowDefinition Height="Auto" />
        <RowDefinition />
    </Grid.RowDefinitions>

    <dxb:ToolBarControl>
        <dxb:BarButtonItem Content="Show Column Chooser"
                           Command="{Binding View.Commands.ShowColumnChooser, ElementName=grid}" />
    </dxb:ToolBarControl>

    <dxg:GridControl x:Name="grid" Grid.Row="1" ...>
        ... 
    </dxg:GridControl>
</Grid>

See Also

DataViewCommandsBase Class

DataViewCommandsBase Members

DevExpress.Xpf.Grid Namespace