How to hide status bar in UIImagepickercontroller?

This worked fine for me:

- (void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated
{
    [[UIApplication sharedApplication] setStatusBarHidden:YES];
}

Edit: As of today i just found out that in your info.plist, if you just copy-paste view controller-based status bar appearance there it won’t work … you have to hit enter on a property, and scroll to the last one of them so you will have autocomplete to :view controller-based status bar appearance and an boolean, with no. I tried multiple times but it does not work just copying. Have a nice day.

Leave a Comment