How to automatically resize a column ?

6 posts, 0 answers
  1. Thomas LEBRUN
    Thomas LEBRUN avatar
    66 posts
    Member since:
    Sep 2009

    Posted 22 Oct 2009 Link to this post

    Hi,

    I would like to know how I can automatically resize a column (simulate a double-clic on the grid column separator) so the content is not truncated.

    I've found nothing to do this: is it possible ?


    Thanks !
  2. Thomas LEBRUN
    Thomas LEBRUN avatar
    66 posts
    Member since:
    Sep 2009

    Posted 22 Oct 2009 Link to this post

    Hi,

    Nobody got an idea ? :(


    Thanks !
  3. DevCraft banner
  4. Hristo
    Admin
    Hristo avatar
    832 posts

    Posted 23 Oct 2009 Link to this post

    Hi Thomas LEBRUN,

    Double Clicking on the thumb that is used to resize the column will make it auto size.
    The thumb is between two columns.
    Also in Q3 beta 2 release you can set radGridView.Columns[0].Width = GridViewLength.Auto
    It is the same as double clicking the resize thumb.

    Kind regards,
    Hristo
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  5. Thomas LEBRUN
    Thomas LEBRUN avatar
    66 posts
    Member since:
    Sep 2009

    Posted 23 Oct 2009 Link to this post

    Hi Hristo;

    Using GridLength.Auto does what I need: thanks !

    Thomas
  6. Sam Smith
    Sam Smith avatar
    1 posts
    Member since:
    Jun 2009

    Posted 03 Dec 2009 Link to this post

    When I try to double click on what I think is the thumb in between the two columns I don't get the auto size functionality that I'm expecting.  Rather, I get a slight movement on the first click (resize), then I get a sort on the column since the with of the column changed on the first click, my mouse is now on the column header rather than in the middle.

    I experimented on the demo site and had the same results. 
    http://demos.telerik.com/aspnet-ajax/grid/examples/client/resizing/defaultcs.aspx

    Please let me know if I'm doing something wrong or if I don't understand something.

    Thank you!

    (Thanks for the reply - I missed that this is the Silverlight forum, is there an autosize function within the asp.net ajax radgrid?)
  7. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 04 Dec 2009 Link to this post

    Hello,

    This demo is for our ASP.NET AJAX grid - you can check RadGridView for Silverlight demos here:
    http://demos.telerik.com/silverlight/#GridView/FirstLook

    Regards,
    Vlad
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top
DevCraft banner