【问题标题】:how to check if the interstitial of Chartboost loaded? and otherwise use admob如何检查 Chartboost 的插页式广告是否加载?否则使用 admob
【发布时间】:2015-03-03 02:49:59
【问题描述】:

我是android的初学者,我想投放广告。我想知道如何检查 charboost 的插页式是否已加载。可以吗?:

Chartboost.cacheInterstitial(CBLocation.LOCATION_DEFAULT);
                if(Chartboost.hasInterstitial(CBLocation.LOCATION_DEFAULT)){
                    //displayInterstitial();
                    Chartboost.showInterstitial(CBLocation.LOCATION_DEFAULT);
                }else{
                    displayInterstitial();
                }

我认为它有效,但不想搞砸

【问题讨论】:

  • 你读过他们的文档吗?
  • 是的,但我没有找到这个主题。反正我的英文不是很好,可能是这个原因,所以请教一下。

标签: android eclipse admob interstitial chartboost


【解决方案1】:

它位于Chartboost Documentation。请参阅高级主题中的“缓存”。

安卓

if (Chartboost.hasInterstitial(CBLocation.LOCATION_HOME_SCREEN)) {
    Chartboost.showInterstitial(CBLocation.LOCATION_HOME_SCREEN);
}
else {
    Chartboost.cacheInterstitial(CBLocation.LOCATION_HOME_SCREEN);
}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-08-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-04-05
    相关资源
    最近更新 更多