Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8233021
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T17:59:52+00:00 2026-06-07T17:59:52+00:00

I do not manage to have iAd working in storyboard, within a UITableViewController. This

  • 0

I do not manage to have iAd working in storyboard, within a UITableViewController.

This is basically what I have done so far:
In storyboard, I have dragged an iAd banner view in the bottom of the scene of my UITableViewController. (I was not able to set the banner in the view itself as storyboard prevents it. I could only drag the iAd object next to the first responder and UITableViewController’s icons.)

In the header of the UITAbleViewController, I have:

#import <UIKit/UIKit.h>
#import "ListViewController.h"
#import <iAd/iAd.h>

@interface ListViewController : UITableViewController <ADBannerViewDelegate>{
    bool bannerIsVisible;
}

@property (strong, nonatomic) IBOutlet ADBannerView *iAd;

@end

In the implementation of the UITableViewController, I have:

- (void)viewDidLoad
{
  [super viewDidLoad];

  iAd.delegate = self;
  // iAd.frame = CGRectMake(0.0,200.0,iAd.frame.size.width,iAd.frame.size.height); // does not work
  //  self.tableView.tableFooterView = iAd;   // Display the banner at the middle of the screen (depending upon the number item of the table)

  // Do not know how to have the default banner to appear at the very bottom of the screen (behind the tab bar) when the view is loaded ?

} 


- (void)bannerView:(ADBannerView *)banner didFailToReceiveAdWithError:(NSError *)error
{
  NSLog(@"didFailToReceiveAdWithError");
  if (bannerIsVisible)
  {
    [UIView beginAnimations:@"animateAdBannerOff" context:NULL];
    banner.frame = CGRectMake(0.0,350.0,banner.frame.size.width,banner.frame.size.height);
    [UIView commitAnimations];
    bannerIsVisible = NO;
  }
}

- (void)bannerViewDidLoadAd:(ADBannerView *)banner
{
  NSLog(@"bannerViewDidLoadAd");
  if (!bannerIsVisible)
  {
    [UIView beginAnimations:@"animateAdBannerOn" context:NULL];
    banner.frame = CGRectMake(0.0,317.0,banner.frame.size.width,banner.frame.size.height);
    [UIView commitAnimations];
    bannerIsVisible = YES;
  }
}

The idea is to have the banner appearing at the bottom of the screen and to show it above the tab bar is the banner load is succesfulf.

The problem I have: with this configuration I can see that sometimes the method “didFailToReceiveAdWithError” is called and sometimes the “bannerViewDidLoadAd” one, but in each case the banner is not shown.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T17:59:53+00:00Added an answer on June 7, 2026 at 5:59 pm

    Your problem is a common one. It’s not happening due to storyboard but rather is happening due to the fact the you are using a UITableViewController. UITableViewControllers give you a lot for free, but they do require a few things. One of those ‘things’ is that they demand their view be a UITableView.

    You have a few options. Here are a couple of the preferred ones.

    1) Add your iAd as the tableFooterView. This requires some extra work to keep it onscreen while scrolling as out lined in my answer to this question.

    2) Convert your UITableViewController subclass to be a UIViewController subclass. This is interestingly what the OP of the question linked above ended up doing. Essentially then you can animate the (now a subview) tableView’s frame while animating the iAd. And then it will work as expected. I outlined the basic steps for converting to a UIViewController subclass in a .xib file in this answer, most of it should be applicable to you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm adding iAd on my app.... I managed to have the banner sliding from
I can not manage to have both i18n and tinyMCE widgets on internationalised fields.
Hi, I could not manage to get where i want with my carousel. This
I am not new to Wordpress, but new to PHP. I have managed to
I have gone through SIP Manager Documentation , it says - Not all Android-powered
I'm looking for a web application to manage tasks (not necessary programming-oriented) for a
I just got a site to manage, but am not too sure about the
I'm looking for a simple C# solution to manage a playlist. Not the actual
D:\zjm_code\basic_project>python manage.py syncdb Error: One or more models did not validate: topics.topic: Accessor for
I have an Excel sheet and have this formula below. I would like to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.