I have one viewcontroller
in application that supports landscape and portrait orientations.
On a button click, a popup appears where I should enter the nam
Create subclass of UIAlertController
MyAlertController.h //header file
@interface MyAlertController : UIAlertController
@end
MyAlertController.m
@implementation MyAlertController
- (BOOL)shouldAutorotate
{
return NO;
}
-(UIInterfaceOrientationMask)supportedInterfaceOrientations
{
[super supportedInterfaceOrientations];
return UIInterfaceOrientationMaskLandscape;
}
@end