0

I've got a view which looks like this:

http://www.imgbox.de/users/public/images/W3pITuCTOw.png

As you can see, it's the standard Design.

When I click in Visual Studio at 'Snapped', it looks like this:

www.imgbox.de/users/public/images/8FW93PIwbt.png

As you can see, the second Grid "West" is now below the left Grid "Ost".

The problem is, that it won't work when I start the app (It keeps the standard) (don't be irritated by the top bar...)

http://www.imgbox.de/users/public/images/C6AYtKnJjO.png

Rudi
  • 926
  • 2
  • 19
  • 38

1 Answers1

0

Problem solved. This has to be in code-behind:

    public MainPage()
    {
        this.InitializeComponent();
        Window.Current.SizeChanged += Current_SizeChanged;  
    }

    void Current_SizeChanged(object sender, Windows.UI.Core.WindowSizeChangedEventArgs e)
    {
        VisualStateManager.GoToState(this, ApplicationView.Value.ToString(), true);
    }
Rudi
  • 926
  • 2
  • 19
  • 38