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
505
MinColumnWidth for all columns
posted

Hi,

I can't seem to find a way to set the minimum column width for all columns. For rows there is a MinRowHeight property on the override but there is no complementary MinColumnWidth.

Although there is a MinWidth on the individual columns, to use this means I have to iterate over all of the columns in initializelayout to set it. However I also want it to apply to any new columns that get added so I must also register for the ListChanged events on the data source (and ensure I get the events after the grid...)

A simple MinColumnWidth on the override would solve this and allow me to easily apply it at the layout or band level. Is there a reason why this isn't provided or has it just not been considered before? Or am I missing something obvious?

Thanks,

Martin.

Parents
No Data
Reply
  • 469350
    Suggested Answer
    Offline posted

    Hi Martin,

    You're not missing anything, there's no MinWidth for columns except on each individual column. I guess for rows, it makes sense to have this property on a high level since all rows in the band are essentially the same.

    But all columns are (usually) different and I guess it just never came up before now.

    You should Submit a feature request to Infragistics.

    In the mean time, you could handle the BeforeColPosChanged event and cancel the event if the user tries to size a column too small. It's not an ideal solution, since it won't stop the drag indicator from moving smaller, but it should work.


Children
No Data