This is a migrated thread and some comments may be shown as answers.

Locked columns with an auto sized column grid

1 Answer 933 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Vance
Top achievements
Rank 1
Vance asked on 08 Feb 2017, 08:23 PM

Hello,

We're trying to find a way to setup a data grid that has locked columns but also has the column widths decided by the content of the cells.  When switching the grid from the default Scrollable true, to false, we get the auto table layout but lose the locked columns.  Is there a way to have both?  We're trying to avoid setting specific widths for each column in the grid.

Thanks

1 Answer, 1 is accepted

Sort by
0
Patrick | Technical Support Engineer, Senior
Telerik team
answered on 09 Feb 2017, 05:27 PM
Hi Vance,

In order for a Kendo Grid to have locked columns, there are certain settings that need to be set.

- Enable scrolling.
- Lock at least one column initially.
- Define the height of the Grid.
- Set explicit pixel widths to all columns to allow the Grid to adjust the layout of the frozen and non-frozen table parts.
- Make sure that the total width of all locked columns is equal to or less than the width of the Grid minus three times the width of the scrollbar.

Please take a look at this documentation which details the requirements for locked columns.   

I hope this clears things.

Regards,
Patrick
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Grid
Asked by
Vance
Top achievements
Rank 1
Answers by
Patrick | Technical Support Engineer, Senior
Telerik team
Share this question
or