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

Programatically changing RadPaneGroup Height

3 Answers 107 Views
Docking
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Andrew
Top achievements
Rank 1
Andrew asked on 29 Oct 2012, 01:36 PM
I have a RadSplitContainer that looks like so:

<telerik:RadSplitContainer x:Name="radSplitContainer" Orientation="Vertical">
    <telerik:RadPaneGroup>
        <telerik:RadPane CanFloat="False" CanUserClose="False" CanUserPin="False" PaneHeaderVisibility="Collapsed">
                <telerik:RadTileView x:Name="tileView"/>
        </telerik:RadPane>
    </telerik:RadPaneGroup>
    <telerik:RadPaneGroup x:Name="gridPaneGroup">
        <telerik:RadPane CanFloat="False" CanUserClose="False" CanUserPin="False" PaneHeaderVisibility="Collapsed" x:Name="gridPane" IsHidden="False">
            <local:MyControl/>
        </telerik:RadPane>
    </telerik:RadPaneGroup>
</telerik:RadSplitContainer>

Is there a way in which I can programatically change the Height of the second RadPaneGroup? I've tried doing something like:

this.gridPaneGroup.Height = 150;

but it does not appear to change the height of the pane at all. Any help on this would be appreciated.

Thanks.

3 Answers, 1 is accepted

Sort by
0
Vladi
Telerik team
answered on 01 Nov 2012, 01:41 PM
Hello Andrew,

In RadDocking changing the size of a PaneGroup to a specific size is not supported. By design in the control all PaneGroups in a specific SplitContainer take the size of that container. It is not possible to explicitly set a size to a group but it is possible to set a relative size between PaneGroups.

You can read this help article that goes through on how to Set Relative Sizes to RadPanegroups.

All the best,
Vladi
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Andrew
Top achievements
Rank 1
answered on 01 Nov 2012, 03:47 PM
That would help, but I don't see a way to set that property programatically. Is there a way?
0
Vladi
Telerik team
answered on 02 Nov 2012, 02:37 PM
Hi Andrew,

In order to set the RelativeSize from the code behind you will need to use the SetRelativeSize() method of the ProportionalStackPanel class.

The next code snippet shows how to change the relative size of the gridPaneGroup from your example:
Telerik.Windows.Controls.ProportionalStackPanel.SetRelativeSize(this.gridPaneGroup, new Size(200, 200));

Hope this helps.

Regards,
Vladi
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
Docking
Asked by
Andrew
Top achievements
Rank 1
Answers by
Vladi
Telerik team
Andrew
Top achievements
Rank 1
Share this question
or