Is it possible to have the status bar hidden in just one scene in the Storyboard?
For example:
I want it hidden in "ViewController A", but when moving via a segue to "ViewController B" (eg, a Navigation Controller) the status bar will be shown.
I gather you can disable it throughout the app, but how do you do it for just one ViewController?
The suggestion from below does work, however when switching to the Navigation Controller it seems to cause the nav bar to be drawn in the wrong location.

How about
- (void)viewWillAppear:(BOOL)animated{
[super viewWillAppear:animated];
[[UIApplication sharedApplication] setStatusBarHidden:YES];
}
- (void)viewWillDisappear:(BOOL)animated{
[[UIApplication sharedApplication] setStatusBarHidden:NO];
[super viewWillDisappear:animated];
}
Just put the code on your ViewController.m (in iOS7, Xcode 5)
- (BOOL) prefersStatusBarHidden {
return YES;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With