This is a migrated thread and some comments may be shown as answers.

With Text Wrapping on, Row Height not autosizing

1 Answer 549 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
Thomas asked on 30 May 2014, 03:44 PM
I'm having problems with row height not auto - sizing with text wrapping on.  When I enter a long string, it will wrap to two lines in the row, but it doesn't display the third row. I would like to row height expand to automatically to display all the text.

Below is the grid XAML code I'm using.

telerik:RadGridView Grid.Row="1" ScrollViewer.HorizontalScrollBarVisibility="Disabled"
ItemsSource="{Binding Path=CustomSqlStatus}"
                    CanUserDeleteRows="False" CanUserInsertRows="False" CanUserSelect="False"
                    UseLayoutRounding="True" CanUserFreezeColumns="False"
                    CanUserSortColumns="False" Padding="2" ShowGroupPanel="False"
                    IsFilteringAllowed="False" CanUserSortGroups="False"
                    RowIndicatorVisibility="Hidden" MaxColumnWidth="400">
    <telerik:GridViewDataColumn DataMemberBinding="{Binding Path=SqlCommandName}"
                                Header="Command Name"
                                HeaderCellStyle="{StaticResource BoldFont}" />
    <telerik:GridViewDataColumn DataMemberBinding="{Binding Path=Comments}"
                                HeaderCellStyle="{StaticResource BoldFont}" TextWrapping="Wrap" />
    <telerik:GridViewDataColumn DataMemberBinding="{Binding Path=SQL}"
                                HeaderCellStyle="{StaticResource BoldFont}" TextWrapping="Wrap"/>

1 Answer, 1 is accepted

Sort by
Telerik team
answered on 02 Jun 2014, 12:08 PM
Hello Thomas,

I am not really sure why the TextWrapping property set to Wrap wouldn't work in your case. In order to reproduce the issue from your description I set the RowHeight property of the GridView to a fixed value. However, it seams to be working as intended.

Also, I attached the sample project that I used. Could you please edit it in a way that it reproduces the described behavior? 

Boris Penev
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.
Asked by
Top achievements
Rank 1
Answers by
Telerik team
Share this question