2013-06-04 148 views
0

我已經在另一個應用程序之前設置了AdWhirl,但現在由於某種原因它不適用於我。Adwhirl廣告不顯示

我設置了AdMob並檢索了publisherID,然後將其添加到AdWhirl網站並配置了百分比,但我沒有看到任何廣告。我甚至看不到測試廣告。

我這樣做:

public class Juggle2 extends Activity { 

//... 
AdWhirlLayout _ad; 
public MainMenu mm; 


@Override 
public void onCreate(Bundle savedInstanceState) { 
    super.onCreate(savedInstanceState); 

    _ad = new AdWhirlLayout(this,"4ae6c5e2da3a4f20898312265874b1d3"); 
    RelativeLayout.LayoutParams adWhirlLayoutParams = new RelativeLayout.LayoutParams(320, 52); 

    RelativeLayout rl = new RelativeLayout(this); 
    rl.addView(_ad,adWhirlLayoutParams); 

    mm = new MainMenu(this); 
    rl.addView(mm); 


    requestWindowFeature(Window.FEATURE_NO_TITLE); 
     setContentView(rl); //Start the menu 

    } 

然後我得到這個。

06-03 22:28:07.284: D/AdWhirl SDK(17832): Showing ad: 
06-03 22:28:07.284: D/AdWhirl SDK(17832): nid: 405f63ed17714f3a9f24393ae7767199 
06-03 22:28:07.284: D/AdWhirl SDK(17832): name: admob 
06-03 22:28:07.284: D/AdWhirl SDK(17832): type: 1 
06-03 22:28:07.284: D/AdWhirl SDK(17832): key: a151ad4db66993b 
06-03 22:28:07.284: D/AdWhirl SDK(17832): key2: 
06-03 22:28:07.284: D/AdWhirl SDK(17832): Valid adapter, calling handle() 
06-03 22:28:07.342: I/webclipboard(17832): clipservice: [email protected] 
06-03 22:28:07.354: W/AdWhirl SDK(17832): Caught an exception in adapter: 
06-03 22:28:07.354: W/AdWhirl SDK(17832): java.lang.NoSuchMethodError: com.google.ads.AdRequest.setGender 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.adapters.GoogleAdMobAdsAdapter.requestForAdWhirlLayout(GoogleAdMobAdsAdapter.java:86) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.adapters.GoogleAdMobAdsAdapter.handle(GoogleAdMobAdsAdapter.java:60) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.adapters.AdWhirlAdapter.handle(AdWhirlAdapter.java:168) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.AdWhirlLayout.handleAd(AdWhirlLayout.java:231) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.AdWhirlLayout.access$300(AdWhirlLayout.java:53) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.adwhirl.AdWhirlLayout$HandleAdRunnable.run(AdWhirlLayout.java:399) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at android.os.Handler.handleCallback(Handler.java:587) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at android.os.Handler.dispatchMessage(Handler.java:92) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at android.os.Looper.loop(Looper.java:130) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at android.app.ActivityThread.main(ActivityThread.java:3687) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at java.lang.reflect.Method.invokeNative(Native Method) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at java.lang.reflect.Method.invoke(Method.java:507) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600) 
06-03 22:28:07.354: W/AdWhirl SDK(17832): at dalvik.system.NativeStart.main(Native Method) 
06-03 22:28:07.354: D/WML_SISO(17832): InitPasteboardJni 
06-03 22:28:07.358: E/AdWhirl SDK(17832): nextRation is null! 
06-03 22:28:07.358: D/AdWhirl SDK(17832): Will call rotateAd() in 30 seconds 
06-03 22:28:11.635: W/IInputConnectionWrapper(17832): getExtractedText on inactive InputConnection 
06-03 22:28:11.659: W/IInputConnectionWrapper(17832): getExtractedText on inactive InputConnection 

回答

1

確保您正在編譯AdMob/AdWhirl SDK的最新版本。

AdMob SDK在某些時候更改了其AdRequest設置方法,例如setGender返回AdRequest而不是void。然後更新AdWhirl以針對新版本的SDK進行編譯。

因此,如果您有一個針對void setGender()方法編譯的AdWhirl版本,但與AdRequest setGender()捆綁在一起的AdMob SDK(反之亦然),則會出現此錯誤。

+0

這很有道理。我會試試這個。 – Houseman