New to Kendo UI for jQuery? Start a free 30-day trial

Unlocks (unfreezes) a column.

Parameters:columnNumber|String

The index of the column or the field to which the columns is bound.

In order to use this method, the grid must be initialized with at least one locked column, and there should be locked columns left after the target column is unlocked.

<div id="grid"></div>
<script>
$("#grid").kendoGrid({
  columns: [
    { field: "name", width: 400, locked: true },
    { field: "age", width: 200, locked: true },
    { field: "hometown", width: 400 },
    { field: "siblings", width: 200 }
  ],
  dataSource: [
    { name: "Jane Doe", age: 30, hometown: "Sofia, Bulgaria", siblings: 3 },
    { name: "John Doe", age: 33, hometown: "Boston, MA, USA", siblings: 1 }
  ]
});
var grid = $("#grid").data("kendoGrid");
grid.unlockColumn("name");
</script>

To unlock a column when it is the only one locked use the setOptions method of the Grid.

<div id="grid"></div>
<script>
  $("#grid").kendoGrid({
    columns: [
      { field: "name", width: 400, locked: true },
      { field: "age", width: 200 },
      { field: "hometown", width: 400 },
      { field: "siblings", width: 200 }
    ],
    dataSource: [
      { name: "Jane Doe", age: 30, hometown: "Sofia, Bulgaria", siblings: 3 },
      { name: "John Doe", age: 33, hometown: "Boston, MA, USA", siblings: 1 }
    ]
  });

  var grid = $("#grid").data("kendoGrid");
  var columns = grid.getOptions().columns;
  columns[0].locked = false;

  grid.setOptions({
    columns: columns
  })
</script>
Not finding the help you need?
Contact Support