gpt4 book ai didi

android - Adwhirl 不显示来自 ad mob 的广告,同时它显示自家广告

转载 作者:太空狗 更新时间:2023-10-29 13:42:19 25 4
gpt4 key购买 nike

现在我一直在尝试将 adwhirl 集成到我的应用程序中,它不显示来自 admob 提供商的任何添加。但它会显示自家广告,这似乎没有任何问题

我添加了日志猫文件

为了验证 admob 的工作,我也与同一个应用程序进行了交互,它没有显示任何问题

任何帮助将不胜感激

提前致谢

11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): Showing ad:
11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): nid: 95eb0bdbbc484f8a86e69d15e04f7644
11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): name: admob
11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): type: 1
11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): key: a14ce50397c3043
11-19 15:18:33.149: DEBUG/AdWhirl SDK(572): key2:
11-19 15:18:33.149: INFO/dalvikvm(572): Failed resolving Lcom/adwhirl/adapters/AdMobAdapter; interface 88 'Lcom/admob/android/ads/AdListener;'
11-19 15:18:33.149: WARN/dalvikvm(572): Link of class 'Lcom/adwhirl/adapters/AdMobAdapter;' failed
11-19 15:18:33.159: WARN/AdWhirl SDK(572): Caught an exception in adapter:
11-19 15:18:33.159: WARN/AdWhirl SDK(572): java.lang.Exception: Invalid adapter
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.adwhirl.adapters.AdWhirlAdapter.handle(AdWhirlAdapter.java:141)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.adwhirl.AdWhirlLayout.handleAd(AdWhirlLayout.java:163)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.adwhirl.AdWhirlLayout.access$3(AdWhirlLayout.java:151)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.adwhirl.AdWhirlLayout$HandleAdRunnable.run(AdWhirlLayout.java:316)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at android.os.Handler.handleCallback(Handler.java:587)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at android.os.Handler.dispatchMessage(Handler.java:92)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at android.os.Looper.loop(Looper.java:123)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at android.app.ActivityThread.main(ActivityThread.java:4627)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at java.lang.reflect.Method.invokeNative(Native Method)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at java.lang.reflect.Method.invoke(Method.java:521)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
11-19 15:18:33.159: WARN/AdWhirl SDK(572): at dalvik.system.NativeStart.main(Native Method)

下面添加代码

private static final String COMPANY_NAME = "soft";
private static final String APP_NAME = "firstapplication";
private static LogindbAdapter dbAdapter;


public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

AdManager.setInTestMode(true);


AdView adView=(AdView)findViewById(R.id.ad);
adView.requestFreshAd();

dbAdapter=new LogindbAdapter(getBaseContext());
LinearLayout layout=(LinearLayout) findViewById(R.id.layout_ad);

try
{


AdWhirlAdapter.setGoogleAdSenseCompanyName(COMPANY_NAME);
AdWhirlAdapter.setGoogleAdSenseAppName(APP_NAME);

;
ZestAdzAdapter.setGoogleAdSenseAppName(APP_NAME);
ZestAdzAdapter.setGoogleAdSenseCompanyName(COMPANY_NAME);



AdManager.setPublisherId("a14ce50397c3043");



AdWhirlLayout adWhirlLayout=new AdWhirlLayout(this,"XXXXXXXX");

//handle(adWhirlLayout,this.Ration);

final int DIP_WIDTH = 320;
final int DIP_HEIGHT = 52;
final float DENSITY = getResources().getDisplayMetrics().density;
int scaledWidth = (int) (DENSITY * DIP_WIDTH + 0.5f);
int scaledHeight = (int) (DENSITY * DIP_HEIGHT + 0.5f);

RelativeLayout.LayoutParams adwp =
new RelativeLayout.LayoutParams(scaledWidth, scaledHeight);

layout.addView(adWhirlLayout,adwp);
layout.invalidate();



}
catch(Exception e)
{
Log.e("ad whirl", "un able to create adwhirl layout", e);
}

最佳答案

我遇到了类似的问题,

如果每个网络 sdk 都已集成(eclipse、设置、构建路径)并包含为 jar 文件,请尝试仔细检查

很好看 && 最好的问候,麦克

编辑:

嘿 Kariyachan,很抱歉这么晚才回复,没有意识到答案。 Admob 仍然提供很少的广告。zestadz 不支持德国应用程序的广告。所以这对我来说是个问题 :(.... 但我可以推荐 .. http://www.millennialmedia.com/ ... :=) 他们总是有东西要展示... :) 真的很抱歉..我的广告问题一直存在..我也没有得到基于位置的广告...这就是我现在遇到的问题..

还有一件事提高了我的广告效果.. a*将 AdWhirlInterface*(实现)添加到您开始转换广告的 Activity 中从..并设置接口(interface)监听器..通过代码..类似于 A*dWhirlAdapter.setInterfaceAdapter(this)*(如果它是当前 Activity )

关于android - Adwhirl 不显示来自 ad mob 的广告,同时它显示自家广告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4223846/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com