Iphone:有没有办法强制 ADBanner 显示广告?

发布于 2024-10-31 22:14:40 字数 225 浏览 2 评论 0原文

各位, 我在应用程序开发方面还是个新手。无论如何,我学习...

所以此时,当我尝试使用 ADBanner 时,我想知道是否有办法强制 ADBannerView 显示广告?

我希望用户在某个时间点击广告,但如果在这个特定时刻广告没有显示在横幅中,我的应用程序肯定会失去使用的机会......

提前感谢您的任何想法。

Smaz

(抱歉我的英语不是我的母语)

Dear all,
I'm quite new in app development. Anyway, i learn...

So at this time, as i'm trying to use ADBanner, i wonder if there is a way to force a ADBannerView to display an ad ?

I want the user to clic the ad at a certain time, but if at this particular instant the ad is not displayed in the banner my app will certainly lost chance to be used ...

Thanks in advance for any idea.

Smaz

(sorry for my english which is not my native language)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

相思碎 2024-11-07 22:14:40

没有朋友你无法控制这个。未上传到应用程序商店时,它显示广告横幅运行成功,上传到应用程序商店后,它显示广告的

no friend you cannot control this . The time it is not uploaded to app store it shows ad banner running successfully and after upload to app store it shows ad's

白云不回头 2024-11-07 22:14:40

不,你无法控制它。然而,更好的方法是隐藏横幅,直到其中没有广告为止。为此,您需要处理 的委托方法iAdView

viewDidLoad 中隐藏横幅,然后在 bannerViewDidLoadAd 委托方法中显示它。

// Called when a new banner advertisement is loaded
-(void)bannerViewDidLoadAd:(ADBannerView *)banner;

// Called when a banner view fails to load a new advertisement
-(void)bannerView:(ADBannerView *)banner
    didFailToReceiveAdWithError:(NSError *)error

No, you can't control it. However, the better way is to hide the banner until there is no Ad in it. For the purpose you need to handle delegate methods of the iAdView

Hide the banner in viewDidLoad then show it in bannerViewDidLoadAd delegate method.

// Called when a new banner advertisement is loaded
-(void)bannerViewDidLoadAd:(ADBannerView *)banner;

// Called when a banner view fails to load a new advertisement
-(void)bannerView:(ADBannerView *)banner
    didFailToReceiveAdWithError:(NSError *)error
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文