Reputation: 105
As soon as my app loads I request an ad using this code in viewDidLoad:
self.bannerView = [[GADBannerView alloc]initWithFrame:CGRectMake(0, 421, 320, 50)];
self.bannerView.adUnitID = @"ca-app-pub-3508264504594125/9347203891";
self.bannerView.rootViewController = self;
self.bannerView.delegate = self;
[self.bannerView loadRequest:[GADRequest request]];
On average it takes 5 seconds from the time I request the ad until adViewDidReceiveAd is called and the ad is displayed.
When the user taps on a button the next view controller is displayed, and an ad is called using the same code. However, this time it takes an average of 11-12 seconds to display the ad. By this time, the user will most likely have moved on without seeing the ad.
Is there any reason why this would happen?
Upvotes: 0
Views: 765
Reputation: 605
I had the same problem. If you have all your UIViewController
embeded in UINavigationController
you should add a ad banner to UINavigationController
parent view controller and make navigation controller smaller (navigation controller and banner should be visible when GADRequest
finished). This way ad will be independent from a current root view controller and in addtion you can fully control when show or hide your ad.
Upvotes: 1