I have a Frame in my XAML:
<Frame Grid.Row="1" Content="{Binding MainContent}" Margin="8" NavigationUIVisibility="Hidden" />
The content is a Page which is set in the code, something like this:
MainContent = new MyPage();
I want to bind the width and height of MyPage to the width and height of the parent Frame.
The Frame is in a grid row, so will resize with the window.
Set both your MyPage’s HorizontalAlignment and VerticalAlignment properties to “Stretch”, and its Margin to 0. If that is not enough, set the Frame’s HorizontalContentAlignment and VerticalContentAlignment to “Stretch”, also.
To debug, first check if your Frame is in fact following its parent, changing its background or doing something alike. Check if your page’s Height and Width are set to Auto and MaxHeight and MaxWidth are 0. Check it also for child controls in your page.
Sometimes Blend may override this properties with fixed values or set them when autogenerating controls.
For example, when you use the “Group” command to wrap child elements, the generated panel control may come with fixed Width and Height.
Another case: when you change the type of a grid row or column size type (using the icon on the designer) without having its properties showing in the properties view, Blend may set a MinimumWidth/Height. It happens especially when changing the size type to auto.