Empty column always added as the last column in RadGridView

7 posts, 0 answers
  1. veena
    veena avatar
    32 posts
    Member since:
    Mar 2009

    Posted 26 Nov 2009 Link to this post

    Hi,

    We use a radgridview. We have set the autogeneratedcolumns=false. The problem is always an empty column is added as the last column in the radgridview.

    Can you please help to get rid of the column.


    Thanks in advance.
    VR
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 26 Nov 2009 Link to this post

    Hi,

    You most probably refer to the stretched grid rows? Actually this is not additional column - rows are just measured with available width exactly in the same way as in standard Silverlight DataGrid.

    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.
  3. DevCraft banner
  4. veena
    veena avatar
    32 posts
    Member since:
    Mar 2009

    Posted 26 Nov 2009 Link to this post

    Hi,

    Thanks for the immediate response.

    How can we prevent that. We dont want the column width to be hardcoded.

    Thanks in advance
    VR
  5. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 27 Nov 2009 Link to this post

    Hi,

    I don't believe that we have hard-coded column width. By default grid columns are with auto width (depends on the cells content) you can however apply different behavior using ColumnWidth property of the grid (for all columns) or Width property per column. For example if you want to stretch all columns you can set  ColumnWidth="*" - you can find screenshot attached.

    Sincerely yours,
    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.
  6. veena
    veena avatar
    32 posts
    Member since:
    Mar 2009

    Posted 27 Nov 2009 Link to this post

    Hi,

    Thanks it solved the issue.

    VR
  7. tegbir
    tegbir avatar
    2 posts
    Member since:
    Dec 2010

    Posted 21 Aug 2014 Link to this post

    Hi, I have set column width to * in GridViewDataColumn. After this change, horizontal scrollbar is not working for Grid. Please help
  8. Boris
    Admin
    Boris avatar
    276 posts

    Posted 21 Aug 2014 Link to this post

    Hello Tegbir,

    By setting the Width property of the GridViewDataColumn to a string that includes the "*" character, you are telling the column to take the remaining available space. This means that if you have enough or extra space the column will allocate it to its width, thus the horizontal scrollbar will not be shown. However, if you have more columns that can be displayed on one screen, the horizontal scrollbar still does not work, would you please provide us with a sample project that reproduces the issue?

    Regards,
    Boris Penev
    Telerik
     
    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
     
Back to Top
DevCraft banner