iAd banner shows empty black space after dismissing modal view

84 views Asked by At

My app shows banner ads at the bottom of UIViewController which is root view using self.canDisplayBannerAds = true in viewDidLoad(). App has a settings view which is a UITableViewController and i am showing the ads there as well in the same way.

When i dismiss the modal view (settings view/table view) the banner ads on root view UIViewController goes away and shows a black rectangular box where iAd banner is supposed to display.

The dismiss action/done button on modal view is a unwind to exit() segue.

I am suspecting it is something to do with modal presentation - over full screen or dismiss action i.e. unwind to exit() segue.

EDIT - Just to validate, I tried various presentation styles for modal view and segue back from settings scene to view scene and it worked. But doesn't work the way i am showing table view/settings page as modal view presentation over full screen

I did some more research but many posts suggest that reason behind as constraints/limitation of using iAd with UITableViewController

I could not identify any details about using iAd with UITableViewController so far. Need help and suggestions.

1

There are 1 answers

1
Daniel Storm On

Move your self.canDisplayBannerAds = true to your viewDidAppear() for each view controller.