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
1233
Columns appear in column chooser but not in ultradatasource
posted

I am binding a grid to a bindablelist of my objects.  I am using an ultradatasource to set the columns that I want to appear.  On one grid, the columns are correct and the column chooser is correct.  However, on another grid, the columns are correct, but the column chooser has unwanted columns marked as hidden, which the user can unhide.

 I am using the true flag during binding to hide new columns, as well as setting the new column behavior to hide.

 What must I be doing to allow these columns to appear in the column chooser?

Parents
  • 469350
    Verified Answer
    Offline posted

    Hiding a column in the grid doesn't automatically hide it from the ColumnChooser. If it did, then once a user hid a column, they would never be able to show it again. 

    What you can do is handle the InitializeLayout event of the grid and loop through the columns. Any columns that are already hidden at that point, you should set ExcludeFromColumnChooser to True.

Reply Children
No Data