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

[Solved] Expander contents does not get all width

1 Answer 99 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Leandro
Top achievements
Rank 1
Leandro asked on 20 Jul 2009, 08:40 PM
Hi, I´m using a data grid inside an expander, but this grid does not get all the expander width. Whats is wrong?
Thanks.


<telerik:RadExpander Grid.Row="4" Expanded="radExpander2_Expanded" MaxHeight="200"
    x:Name="radExpander2" ExpandDirection="Down" IsExpanded="False"
    VerticalAlignment="Top" HorizontalAlignment="Stretch"
    >
        <telerik:RadExpander.Header>
            <TextBlock Text="Cálculo da monodroga acumulada na prescrição" Visibility="Visible" />
        </telerik:RadExpander.Header>
        <telerik:RadExpander.Content>
            <telerik:RadWrapPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Stretch"
      >
                <data:DataGrid x:Name="dgMonodroga" AutoGenerateColumns="False"/>

            </telerik:RadWrapPanel>
        </telerik:RadExpander.Content>
    </telerik:RadExpander>

1 Answer, 1 is accepted

Sort by
0
Miroslav
Telerik team
answered on 28 Jul 2009, 02:24 PM
Hi Leandro,

I am sorry for the delayed reply,

The horizontal WrapPanel will try to arrange its children (in this case the grid) with minimum width and move them to a new row if necessary.

To change this, use a panel that behaves differently - like a grid. It will arrange its children with the available width. 

Does this work for you?

Greetings,
Miroslav
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
GridView
Asked by
Leandro
Top achievements
Rank 1
Answers by
Miroslav
Telerik team
Share this question
or