How is your experience with the OutSystems Community?
16
Views
3
Comments
I want to fixed the last column right most column of my Outsystem Data Grid.
Question

I want to fixed the last column right most column (My actions Edit/Delete buttons columns) of my Outsystem Data Grid. How I can do that I tried css, javascript but nothing worked. and Is there any inbuilt function I checked I couldn't find anything. I have around 34 columns

2026-01-28 16-57-48
Mihai Melencu
Champion

Hi @Anjali Choudhary ,

You can use the following JavaScript code in the grid’s OnInitialize event. This will freeze the last column. You can adjust the configuration as needed. 

  1.     const gridObj = OutSystems.GridAPI.GridManager.GetGridById($parameters.GridWidgetId);
  2.     const grid = gridObj.provider || gridObj._provider;

  3.     if ("frozenCells" in grid) {
  4.         grid.frozenColumns = 0;
  5.         grid.frozenCells = {
  6.             top: 0,
  7.             bottom: 0,
  8.             left: 0,
  9.             right: 1
  10.         };

  11.     }

NOTE: Applying manual freeze column will overwrite this one.

UserImage.jpg
Anjali Choudhary

Hi @Mihai Melencu , 

With the above changes my left most column freeze is removed, I want to freeze first and last column, when I tried like this right column only got freezed for left I used the Grid "FreezeColumns", but it got overide by the below js. 
Kindly suggest how to freeze both left and right columns.

  1.    grid.frozenCells = {
  2.             top: 0,
  3.             bottom: 0,
  4.             left: 0,
  5.             right: 1
  6.         };
2026-01-28 16-57-48
Mihai Melencu
Champion


Hi,

With frozenCells, the supported scenarios are:

  • Freeze columns on the left or on the right
  • Freeze rows at the top or at the bottom
  • Combine one horizontal freeze with one vertical freeze, for example:
    • left + top
    • right + top
    • left + bottom
    • right + bottom

However, there is an important limitation: although the API exposes all four sides, you can only freeze cells on two sides at the same time:

  • One horizontal side: either left or right
  • One vertical side: either top or bottom

So freezing both the first column and the last column in the same grid instance is not supported directly.

You can check the documentation here: FrozenCells API

______

My recommendation would be to place all columns that need to remain frozen on the same side of the grid, preferably on the left side.

From a technical point of view, this is the most stable and supported approach, because the standard freeze behavior works best when freezing a continuous block of columns from one side.

From a UX point of view, having the fixed columns grouped on one side is also cleaner and more predictable for the user.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.