Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
510
Freeze and Unfreeze columns
posted

Hi ,

I have 30 columns in  grid.

When i right click on the  particular column header , pops up menu with freeze and unfreeze menu items.

If i click on the freeze menu item , it should freeze till that column .

If i right  clcik on the 10 th column and click on freeze  , it should freeze 1- 10  column s

 If i right click and click on unfreeze gris should be normal .

Any help.

Thanks.

 

Parents
  • 469350
    Offline posted

    Hi,

    What part of this are you having trouble with? There is no built-in functionality in the grid to do this with a context menu or to freeze multiple columns at once with the grid's UI.

    But you could easily create your own context menu for this.

    You will need to set UseFixedHeaders on the grid's DisplayLayout to true to enable fixed header. You have to be using RowLayoutStyle = None, fixed headers are not supported in RowLayout mode.

    Here's an article that will help you detect which column was right-clicked.

    HOWTO:UltraWinGrid Mouse Position and Column Identification

    To fix a column, you simply set column.Header.Fixed to true.

Reply Children