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
762
Specifying Min and Max column widths
posted

I have created an UltraWinGrid with several columns and they populate and draw OK, but the widths make no sense. Several columns are so narrow on the screen their contents are cut off, while the column third from the end takes up nearly half the grid's width. I cannot resize columns consistently; dragging the vertical bar between the column headers only allows resizing by a few pixels left or right except for the wide column, that I can resize right off the window. Dragging the right edge of the wide column's header past the right edge of the grid, or even the application window containing the grid, draws over top of other apps or the Windows desktop!

I have opened the UltraWinGrid Designer dialog, selected the Band and Columns settings, and set the Width property of the columns appropriately. No effect. Just for giggles, I set the Width property of the wide column to half that of the other columns. No effect, it's still bigger than all other columns and can be resized off the grid. When I let go after dragging the wide column, it redaws with some random width still larger than any other column in the grid.

How can I control the drawn width of the columns in a grid?

Parents
No Data
Reply
  • 455
    Suggested Answer
    posted

    I think you can set the exact pixal of width of each column, but according to your description, I think you need to first set the DisplayLayout.AutoFitStyle property to None and then set the Width property of each column under DisplayLayout.Bands(0).Columns(x).

Children