Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
563 views
in Technique[技术] by (71.8m points)

android - Admob banner and interstitial ads not loading on launcher activity

The first time when I load my app the banner ad and the full screen interstitial ad does not load. Every other time when i hit that (or any other) Activity the ads load fine. This leads me to believe that its not a fill issue. Also i am not using any mediation, just the standard Admob network.

Below is the code i use to load the banner ad

AdView bannerAdView = (AdView)this.findViewById(R.id.adView);
    if (Settings.SHOW_ADS) {
        AdRequest adRequestBanner = new AdRequest.Builder().build();
        bannerAdView.loadAd(adRequestBanner);
    }

Log cat reports back the following error

10-11 21:33:51.749  19409-19439/ W/Ads﹕ There was a problem getting an ad response. ErrorCode: 0
10-11 21:33:51.839  19409-19409/ W/Ads﹕ Failed to load ad: 0
10-11 21:33:47.039  19409-19409/ E/Ads﹕ JS: Uncaught ReferenceError: AFMA_ReceiveMessage is not defined (:1)

Is there anything i can do to make the ad load close to 100% of the time, especially the full screen ad?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Also Your package might be blocked by Google AdMob. If you received a email like this:

Hello,

This email is to alert you that one of your applications is not currently in compliance with our AdMob program policies and as a result, ad serving has been disabled to your application.

Issue ID#: 33943***

Ad serving has been disabled to: APPNAME (com.example.pack)

Action required: Check all other remaining applications in your account for compliance.

Current account status: Active

Violation explanation

GOOGLE PLAY REMOVAL: AdMob publishers are not permitted to abuse or promote the abuse of any Google product, such as Google Play, YouTube, or Blogger. This includes circumventing, or providing the means to circumvent, the policies or terms of these or other Google products, such as by allowing users to download YouTube videos.

If your app is removed by Google Play policy enforcement, please contact Google Play about an app removal here. If Google Play reinstates your app, please submit an appeal to our team.

Action required: Check account for compliance

While ad serving has been disabled to the above app, your AdMob account remains active. We suggest that you take the time to review the rest of your applications to ensure that they’re in compliance with our policies, and to monitor your apps accordingly to reduce the likelihood of future policy emails from us. Additionally, please note that our team reserves the right to disable accounts at any time if we continue to see violations occurring.

Appeals

If you wish to appeal this disabling then you can do so by using our appeal form.

Thank you for your cooperation.

Sincerely,

The Google AdMob Team

So now you need to change your package of your app. on eclipse it is package="com.example" in AndroidManifest.xml file

or

on AndroidStudio applicationId "com.example" in build.gradle file


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...