I tried to find a solution but so much information which doesn't work. My last try was using the following:
UIApplication.sharedApplication().setStatusBarOrientation(UIInterfaceOrientation.LandscapeRight, animated: false)
This however, was deprecated from iOS 9 and couldn't find any way to force rotate with UINavigationController
. My app mainly uses Portrait Orientation and only one view needs to be Landscape. I need to force Landscape on one View and rest to keep as Portrait. Any help would be highly appreciated!
Some of the questions I checked are:
Setting device orientation in Swift iOS
How do I programmatically set device orientation in iOS7?
Why can't I force landscape orientation when use UINavigationController?