Reputation: 19
I am trying to use an iAd Banner in my App. I have different storyboards for the various devices. The iPhone 4/5 versions work but the iPhone 6/6 Plus versions have sizing issues! After I turned off auto layout the iPhone 6/6 Plus versions work, but they aren't in the center of the view! (On the image below)
http://fs2.directupload.net/images/150812/kgdcnt29.png
I thought I could change it with the mode in the attributes inspector but it didn't change!
How do I fix this?
Upvotes: 1
Views: 167
Reputation: 6192
Alltough you solved it, to help out others this is the way to make the iAd Banner fit perfectly every screen size without any need of different storyboard and auto layout! This also positions the Ad at the bottom of the screen.
self.AdBanner.frame = CGRectMake(0, self.view.frame.size.height-self.AdBanner.frame.size.height, self.AdBanner.frame.size.width, self.AdBanner.frame.size.height)
Upvotes: 1