user3847141
user3847141

Reputation: 253

How do i know if the rotation lock is on or off?

I just need to know if there is a way to get the rotation lock status in windows phone 8, for example

if(rotationLock == ON)do stuff;

Upvotes: 0

Views: 169

Answers (1)

Amit Bhatiya
Amit Bhatiya

Reputation: 2621

Unfortunately There is not any method or way to know that Rotation lock is On/Off. but you can set SupportedOrientations and Orientation in Xaml or you can manage Orientation in CS as under:

protected override void OnOrientationChanged(OrientationChangedEventArgs e)
{
    if (e.Orientation == PageOrientation.LandscapeLeft)
        base.OnOrientationChanged(e);
}

Upvotes: 1

Related Questions