Skip to content Skip to sidebar Skip to footer

How To Make Admob Always Shows An Ad On Android?

I know that there is only a certain fill rate that admob can fill. However I want to show something anyway, or it will make my UI inconsistent. I tried to enable the 'house ad', bu

Solution 1:

Admob will always show an ad if possible. And if it can't show a paid ad, it will show one of your house ads. However sometimes it still doesn't pop up so, like you said, you want to check if it appeared and if not, replace it with something else. Create a listener class that extends SimpleAdListener. Then override the onFailedToReceiveAd method like so:

@OverridepublicvoidonFailedToReceiveAd(AdView adView)
            {
                // TODO Auto-generated method stubsuper.onFailedToReceiveAd(adView);
                //Display your other view here.
            }

Check the LunarLander sample to get a better idea.

Post a Comment for "How To Make Admob Always Shows An Ad On Android?"