Orientation Hint for Windows Phone7


In this article I will be a showing you a nice hint for Orientation.

Normally when you first develop and run your application without changing its Orientation, it will use Portrait by default.

1.gif

2.gif

This isn't what we want, is it?

Now get to Orientation Property of the WindowsPhoneApplication:

3.gif


Choose LanscapeRight for example. And you will see in Design Mode that Orientation of the WP7 has changed.

4.gif

Now look at above this, you will see a Yellow-warning box saying:

"This page does not support the current orientation. Click here to enable the page to support all orientations."

5.gif

Using this method now you have support for all the orientations no matter what.

The other alternative way doing this is to change this line:

SupportedOrientations="Portrait" Orientation="LandscapeRight"

Into this one:

SupportedOrientations="PortraitOrLandscape" Orientation="LandscapeRight"

Hope it helps!
 

erver'>
Up Next
    Ebook Download
    View all
    Learn
    View all
    Araf Global is a software consultancy company founded in 2016 focusing on cutting edge technologies.