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
620
Grid - Auto adjust columns width based on content length
posted

I'm developing a web application and I'm using a lot of grid. I'm trying to avoid having a lot of customization for each one of them. I'd like that the grid set each column's initial width based on the content. I. e.:

Short name      Name
JF                  John Foo
AB                 Ana Bar

All values for 'Short name' are 2 chars long, and the longest value for 'Name' is 'John Foo' with 8 chars. So in this case, the grid should set 'Short name' column's width to 20%, and 'Name' column's width to 80%.

In case this functionality does not exisist, could you give me some clues so I know where to start building it?

Thanks,
Diego

Parents
  • 2355
    Verified Answer
    Offline posted

    Hi,

    Thank you for posting in Infragistics forums! Currently we are working towards improving this functionality. You can expect it in one of our future Service Releases. Until then you can set the width of the columns manually in grid’s options.

    Kind regards,
    Petko Zhekov
    Software Developer

Reply Children