Layout problem with column sizes on initial load

2 posts, 0 answers
  1. Kevin Sonney
    Kevin Sonney avatar
    3 posts
    Member since:
    Jun 2010

    Posted 27 Aug 2010 Link to this post

    I'm having layout problems with my grid at the initial load.  A couple of my columns will not auto size properly after they load their data, but as soon as I resize the browser window a bit the layout updates and everything is sized properly.  I've attached two screenshots to show the problem I'm seeing.  I've tried playing with the layout and some different properties, but I can't seem to get it to layout correctly after loading the data.

    Here is my code:
    <Grid Grid.Row="1" DataContext="{Binding Product, ElementName=mThis}" Grid.Column="1">
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="*"/>
                <Border CornerRadius="5" Background="{StaticResource InformationHeaderBrush}" Margin="3" Height="25">
                    <Border Style="{StaticResource BorderGlossEffectStyle}" CornerRadius="5">
                        <TextBlock Text="Exchange Mail Stores" Style="{StaticResource TitleAreaTextStyle}"/>
                <telerik:RadGridView Grid.Row="1" ItemsSource="{Binding MailStores}" CanUserResizeColumns="True" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
                                             CanUserReorderColumns="True" CanUserDeleteRows="False" RowIndicatorVisibility="Collapsed" IsFilteringAllowed="False"
                                             AutoGenerateColumns="False" IsReadOnly="True" CanUserSortColumns="True" CanUserSelect="False"
                                             AutoExpandGroups="True" telerik:StyleManager.Theme="Windows7" Margin="3 0 3 0">
                        <telerik:GroupDescriptor Member="Owner" DisplayContent="Server">
                                <telerik:CountFunction Caption="Total Mail Stores:"/>
                        <telerik:GridViewDataColumn Header="Name" DataMemberBinding="{Binding Name}" Width="*"/>
                        <telerik:GridViewDataColumn Header="Server" DataMemberBinding="{Binding Owner}"/>
                        <telerik:GridViewDataColumn Header="File Size" DataMemberBinding="{Binding Size, Converter={StaticResource BytesToStringConverter}}"/>
                        <telerik:GridViewDataColumn Header="Mailboxes" DataMemberBinding="{Binding Mailboxes}" DataFormatString="N0"/>
                        <telerik:GridViewDataColumn Header="Items" DataMemberBinding="{Binding Items}" DataFormatString="N0"/>
  2. Tsvyatko
    Tsvyatko avatar
    832 posts

    Posted 31 Aug 2010 Link to this post

    Hi Kevin Sonney,

    Based on the code posted I have prepared sample application. However, I am unable to get the issue you are facing. Could you please check the attached project and let me know if the problem can be reproduced. If not could you modify it in order to reproduce this issue.

    Sincerely yours,
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
Back to Top