The iAds where working fine. Then when I really tested, calling up all the different view controllers, it will stop working for some screens.
My app has about 15 screens. Thus when I really debug it I go to all the screens and a iAd object gets created for all of them.
I noticed that if I put break points on the iAds delegate functions, they are all being called. So if I go through and view all 15 screens, I have break points going off in 15 different files, for each iAd created, thus it seems like when you create a window, view controller, it keeps running, even if you call up another screen.
So I tred testing it and just calling up 7 screens, worked fine. After I called up more the 7 screens the iAd no longer worked for the remaing screens, kept calling the
– (void)bannerView:(ADBannerView *)banner didFailToReceiveAdWithError:(NSError *)error
methed.
Has any one else had this problem? I was thinking abut trying have one iAd object and using add and remove subview. Wondering if anybody else had a more simpler solution
Ted
With out knowing the error that is passed into -bannerView:didFailToRecieveAdWithError: it is very hard to give you a thorough answer. Most likely Apple is just not sending a iAd as they don’t always send one. If you would like to have an iAd on every page I recommend creating a class called wholeAppAd that is parented by UIAdBannerView and using this class as though it is a singleton class (http://www.galloway.me.uk/tutorials/singleton-classes/). By doing this you can access the banner view from any controller and add the same banner as a subview. Hope I helped.