I've just implemented iAds in an app with several distinct UIViewControllers.
I have the delegate methods in each one for - (void)bannerViewDidLoadAd:(ADBannerView *)banner
and - (void)bannerView:(ADBannerView *)banner didFailToReceiveAdWithError:(NSError *)error
that show and hide the banner, along with a setup method that creates a banner during viewDidLoad.
I did this by getting everything working in the first UIViewController
and then copying the code to each of the other controllers, along with the ivar
declarations, properties, etc...
This can't be right. Every time I change one, I have to change them all. My question (finally!) is: Is there a way to write these methods once so that all classes have access to them?
Thanks!