This is a migrated thread and some comments may be shown as answers.
Disable column selector in datagrid
3 Answers 30 Views
This is a migrated thread and some comments may be shown as answers.
Safan
Top achievements
Rank 1
Safan asked on 11 Jun 2019, 03:38 PM

Hello,

Do we have an option to disable column selector/rearrange in data grid.

Any help would be highly appreciated. Thank in advance.

3 Answers, 1 is accepted

Sort by
0
Lance | Manager Technical Support
Telerik team
answered on 11 Jun 2019, 04:58 PM
Hi Safan,

The DataGridColumn has a set of common properties you can set to disable certain features like sorting, filtering, etc. Take a look at the documentation for DataGrid Column Properties (e.g. CanUserSort="False").

You can also set this for all columns on the DataGrid object:

<telerikGrid:RadDataGrid
    UserEditMode="None"
    UserFilterMode="Disabled"
    UserGroupMode="Disabled"
    UserSortMode="None" ...>

You can also style parts of the column header to make the buttons transparent. Take a look at the Filter Indicator, Sort Indicator and other related sections in the DataGrid Column Styling documentation.

If you have any trouble or additional DataGrid questions, feel free to open a Support Ticket and share the code that you're using so we can assist directly.

Regards,
Lance | Technical Support Engineer, Principal
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Safan
Top achievements
Rank 1
answered on 12 Jun 2019, 06:31 AM

Hi Lance,

Thanks for your reply.

I am looking for disabling column selector.

Steps:

  • Once the grid is loaded 
  • Click on 3 dots (option) on the column
  • Click on More

Here you can choose the columns to show on the grid. I am looking to disable this feature.

Thank you

~Mohamed Safan

0
Lance | Manager Technical Support
Telerik team
answered on 12 Jun 2019, 04:53 PM
Hello Safan,

Thank you for clarifying what you're looking for. At this time, there are no customization options modify that modify the Options button (in the filter UI popup) functionality.

We do have this request on our backlog. You can add your vote and follow it here - DataGrid: Provide an easy way to show/hide/remove the OptionsButton (Filtering UI)

In the meantime, you can follow this KB article that will show you how to hide the column's options button - How to hide the three dots in column header. For your convenience, here's the snippet:

<dataGrid:DataGridTextColumn.HeaderStyle>
    <dataGrid:DataGridColumnHeaderStyle OptionsButtonTextColor="Transparent" OptionsButtonFontSize="0" BorderColor="#D9D9D9" BorderThickness="1" />
    </dataGrid:DataGridTextColumn.HeaderStyle>
</dataGrid:DataGridTextColumn>

Regards,
Lance | Technical Support Engineer, Principal
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Asked by
Safan
Top achievements
Rank 1
Answers by
Lance | Manager Technical Support
Telerik team
Safan
Top achievements
Rank 1
Share this question
or