: NavigationWindow, . , Height Width .
- wpf
-delete 1, .
App.xaml ( StartupUri):
<Application x:Class="WpfApplication1.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Startup="Application_Startup">
<Application.Resources>
</Application.Resources>
</Application>
App.xaml.cs :
public partial class App : Application
{
private NavigationWindow navigationWindow;
private void Application_Startup(object sender, StartupEventArgs e)
{
navigationWindow = new NavigationWindow();
navigationWindow.Height = 200;
navigationWindow.Width = 100;
var page = new Page1();
navigationWindow.Navigate(page);
navigationWindow.Show();
}
. - :
<Page x:Class="WpfApplication1.Page1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Page1">
<Grid>
<TextBlock>test</TextBlock>
</Grid>
</Page>
!