16

I have a simple WPF application with two xaml Pages. I'd like the app opening with the maximum size of the screen. I've found only answers about WPF Windows, but for Pages there is not a "WindowState" property.

Thanks a lot!

MarianoDiego
  • 171
  • 1
  • 1
  • 3

2 Answers2

29

In your Xaml window definition simply define:

WindowStartupLocation="CenterScreen" WindowState="Maximized"
Hardgraf
  • 2,566
  • 4
  • 44
  • 77
0

You could set the Width and Height property manually according to your current Screen Resolution from here

System.Windows.SystemParameters.PrimaryScreenWidth;
System.Windows.SystemParameters.PrimaryScreenHeight;
coder0815
  • 219
  • 2
  • 8